diff --git a/hifi-src/src/components/Navbar.jsx b/hifi-src/src/components/Navbar.jsx index 60875df..c9b257b 100644 --- a/hifi-src/src/components/Navbar.jsx +++ b/hifi-src/src/components/Navbar.jsx @@ -1,6 +1,6 @@ import { useEffect, useRef, useState } from 'react'; import { createPortal } from 'react-dom'; -import { Link, NavLink, useLocation } from 'react-router-dom'; +import { Link, useLocation } from 'react-router-dom'; import { LayoutDashboard, MessageCircle, Phone, ShoppingBag } from 'lucide-react'; import ThemeToggle from './ThemeToggle.jsx'; import { useAuth } from '../context/AuthContext.jsx'; @@ -188,11 +188,6 @@ export default function Navbar() { }; }, [open]); - const desktopLinkClass = ({ isActive }) => - `rounded-md px-2.5 py-1.5 text-sm font-semibold transition ${ - isActive ? 'text-brand-400' : transparent ? 'text-white/90 hover:text-white' : 'text-neutral-300 hover:text-white' - }`; - useEffect(() => { if (open) { setMounted(true); @@ -269,13 +264,6 @@ export default function Navbar() { - {/* Ab Desktop-Breite die wichtigsten Seiten direkt sichtbar, ohne Umweg ueber das Menue. */} - {/* Immer die Dark-Mode-Logovariante (weisse Wortmarke) - passend zur immer dunklen @@ -285,18 +273,6 @@ export default function Navbar() {
- {phone && ( - trackEvent('contact_call')} - className={`mr-1 hidden items-center gap-2 rounded-full border px-3.5 py-1.5 text-sm font-semibold transition lg:inline-flex ${ - transparent ? 'border-white/40 text-white hover:bg-white/10' : 'border-neutral-700 text-neutral-200 hover:bg-neutral-800' - }`} - > - - {phone} - - )} {AdminIcon} {!open && } diff --git a/hifi/assets/AGB-D307xiNj.js b/hifi/assets/AGB-B90f-gJQ.js similarity index 90% rename from hifi/assets/AGB-D307xiNj.js rename to hifi/assets/AGB-B90f-gJQ.js index 2cf7a2f..ee7525b 100644 --- a/hifi/assets/AGB-D307xiNj.js +++ b/hifi/assets/AGB-B90f-gJQ.js @@ -1 +1 @@ -import{r as a,c as l,b as n,j as e}from"./index-Tg8iNBwT.js";function x(){const[t,s]=a.useState(null);return a.useEffect(()=>{l.get("/legal-pages/agb").then(s).catch(()=>{})},[]),n({title:(t==null?void 0:t.title)||"AGB",description:"Allgemeine Geschäftsbedingungen von HifiPlanet Amorbach.",path:"/agb"}),t?e.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.title}),e.jsx("div",{className:"legal-content text-sm text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:t.body_html}})]}):null}export{x as default}; +import{r as a,c as l,b as n,j as e}from"./index-Cc1wEeIX.js";function x(){const[t,s]=a.useState(null);return a.useEffect(()=>{l.get("/legal-pages/agb").then(s).catch(()=>{})},[]),n({title:(t==null?void 0:t.title)||"AGB",description:"Allgemeine Geschäftsbedingungen von HifiPlanet Amorbach.",path:"/agb"}),t?e.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.title}),e.jsx("div",{className:"legal-content text-sm text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:t.body_html}})]}):null}export{x as default}; diff --git a/hifi/assets/AccountSettings-BjOWslDE.js b/hifi/assets/AccountSettings-D6J5mj1V.js similarity index 99% rename from hifi/assets/AccountSettings-BjOWslDE.js rename to hifi/assets/AccountSettings-D6J5mj1V.js index f42ebae..7e3b629 100644 --- a/hifi/assets/AccountSettings-BjOWslDE.js +++ b/hifi/assets/AccountSettings-D6J5mj1V.js @@ -1,4 +1,4 @@ -import{h as De,r as I,j as u,c as V}from"./index-Tg8iNBwT.js";var Y={},Fe=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then},ye={},S={};let de;const Ue=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];S.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return t*4+17};S.getSymbolTotalCodewords=function(t){return Ue[t]};S.getBCHDigit=function(e){let t=0;for(;e!==0;)t++,e>>>=1;return t};S.setToSJISFunction=function(t){if(typeof t!="function")throw new Error('"toSJISFunc" is not a valid function.');de=t};S.isKanjiModeEnabled=function(){return typeof de<"u"};S.toSJIS=function(t){return de(t)};var W={};(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(s){if(typeof s!="string")throw new Error("Param is not a string");switch(s.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+s)}}e.isValid=function(n){return n&&typeof n.bit<"u"&&n.bit>=0&&n.bit<4},e.from=function(n,r){if(e.isValid(n))return n;try{return t(n)}catch{return r}}})(W);function xe(){this.buffer=[],this.length=0}xe.prototype={get:function(e){const t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)===1},put:function(e,t){for(let s=0;s>>t-s-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var ze=xe;function O(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}O.prototype.set=function(e,t,s,n){const r=e*this.size+t;this.data[r]=s,n&&(this.reservedBit[r]=!0)};O.prototype.get=function(e,t){return this.data[e*this.size+t]};O.prototype.xor=function(e,t,s){this.data[e*this.size+t]^=s};O.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]};var Ke=O,Ce={};(function(e){const t=S.getSymbolSize;e.getRowColCoords=function(n){if(n===1)return[];const r=Math.floor(n/7)+2,o=t(n),i=o===145?26:Math.ceil((o-13)/(2*r-2))*2,l=[o-7];for(let a=1;a=0&&r<=7},e.from=function(r){return e.isValid(r)?parseInt(r,10):void 0},e.getPenaltyN1=function(r){const o=r.size;let i=0,l=0,a=0,c=null,d=null;for(let x=0;x=5&&(i+=t.N1+(l-5)),c=f,l=1),f=r.get(y,x),f===d?a++:(a>=5&&(i+=t.N1+(a-5)),d=f,a=1)}l>=5&&(i+=t.N1+(l-5)),a>=5&&(i+=t.N1+(a-5))}return i},e.getPenaltyN2=function(r){const o=r.size;let i=0;for(let l=0;l=10&&(l===1488||l===93)&&i++,a=a<<1&2047|r.get(d,c),d>=10&&(a===1488||a===93)&&i++}return i*t.N3},e.getPenaltyN4=function(r){let o=0;const i=r.data.length;for(let a=0;a=0;){const i=o[0];for(let a=0;a0){const o=new Uint8Array(this.degree);return o.set(n,r),o}return n};var He=ce,ke={},R={},fe={};fe.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40};var _={};const Se="[0-9]+",Je="[A-Z $%*+\\-./:]+";let J="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";J=J.replace(/u/g,"\\u");const Ye="(?:(?![A-Z0-9 $%*+\\-./:]|"+J+`)(?:.|[\r +import{h as De,r as I,j as u,c as V}from"./index-Cc1wEeIX.js";var Y={},Fe=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then},ye={},S={};let de;const Ue=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];S.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return t*4+17};S.getSymbolTotalCodewords=function(t){return Ue[t]};S.getBCHDigit=function(e){let t=0;for(;e!==0;)t++,e>>>=1;return t};S.setToSJISFunction=function(t){if(typeof t!="function")throw new Error('"toSJISFunc" is not a valid function.');de=t};S.isKanjiModeEnabled=function(){return typeof de<"u"};S.toSJIS=function(t){return de(t)};var W={};(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(s){if(typeof s!="string")throw new Error("Param is not a string");switch(s.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+s)}}e.isValid=function(n){return n&&typeof n.bit<"u"&&n.bit>=0&&n.bit<4},e.from=function(n,r){if(e.isValid(n))return n;try{return t(n)}catch{return r}}})(W);function xe(){this.buffer=[],this.length=0}xe.prototype={get:function(e){const t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)===1},put:function(e,t){for(let s=0;s>>t-s-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var ze=xe;function O(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}O.prototype.set=function(e,t,s,n){const r=e*this.size+t;this.data[r]=s,n&&(this.reservedBit[r]=!0)};O.prototype.get=function(e,t){return this.data[e*this.size+t]};O.prototype.xor=function(e,t,s){this.data[e*this.size+t]^=s};O.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]};var Ke=O,Ce={};(function(e){const t=S.getSymbolSize;e.getRowColCoords=function(n){if(n===1)return[];const r=Math.floor(n/7)+2,o=t(n),i=o===145?26:Math.ceil((o-13)/(2*r-2))*2,l=[o-7];for(let a=1;a=0&&r<=7},e.from=function(r){return e.isValid(r)?parseInt(r,10):void 0},e.getPenaltyN1=function(r){const o=r.size;let i=0,l=0,a=0,c=null,d=null;for(let x=0;x=5&&(i+=t.N1+(l-5)),c=f,l=1),f=r.get(y,x),f===d?a++:(a>=5&&(i+=t.N1+(a-5)),d=f,a=1)}l>=5&&(i+=t.N1+(l-5)),a>=5&&(i+=t.N1+(a-5))}return i},e.getPenaltyN2=function(r){const o=r.size;let i=0;for(let l=0;l=10&&(l===1488||l===93)&&i++,a=a<<1&2047|r.get(d,c),d>=10&&(a===1488||a===93)&&i++}return i*t.N3},e.getPenaltyN4=function(r){let o=0;const i=r.data.length;for(let a=0;a=0;){const i=o[0];for(let a=0;a0){const o=new Uint8Array(this.degree);return o.set(n,r),o}return n};var He=ce,ke={},R={},fe={};fe.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40};var _={};const Se="[0-9]+",Je="[A-Z $%*+\\-./:]+";let J="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";J=J.replace(/u/g,"\\u");const Ye="(?:(?![A-Z0-9 $%*+\\-./:]|"+J+`)(?:.|[\r ]))+`;_.KANJI=new RegExp(J,"g");_.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g");_.BYTE=new RegExp(Ye,"g");_.NUMERIC=new RegExp(Se,"g");_.ALPHANUMERIC=new RegExp(Je,"g");const Oe=new RegExp("^"+J+"$"),$e=new RegExp("^"+Se+"$"),qe=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");_.testKanji=function(t){return Oe.test(t)};_.testNumeric=function(t){return $e.test(t)};_.testAlphanumeric=function(t){return qe.test(t)};(function(e){const t=fe,s=_;e.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},e.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},e.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},e.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},e.MIXED={bit:-1},e.getCharCountIndicator=function(o,i){if(!o.ccBits)throw new Error("Invalid mode: "+o);if(!t.isValid(i))throw new Error("Invalid version: "+i);return i>=1&&i<10?o.ccBits[0]:i<27?o.ccBits[1]:o.ccBits[2]},e.getBestModeForData=function(o){return s.testNumeric(o)?e.NUMERIC:s.testAlphanumeric(o)?e.ALPHANUMERIC:s.testKanji(o)?e.KANJI:e.BYTE},e.toString=function(o){if(o&&o.id)return o.id;throw new Error("Invalid mode")},e.isValid=function(o){return o&&o.bit&&o.ccBits};function n(r){if(typeof r!="string")throw new Error("Param is not a string");switch(r.toLowerCase()){case"numeric":return e.NUMERIC;case"alphanumeric":return e.ALPHANUMERIC;case"kanji":return e.KANJI;case"byte":return e.BYTE;default:throw new Error("Unknown mode: "+r)}}e.from=function(o,i){if(e.isValid(o))return o;try{return n(o)}catch{return i}}})(R);(function(e){const t=S,s=Z,n=W,r=R,o=fe,i=7973,l=t.getBCHDigit(i);function a(y,f,p){for(let w=1;w<=40;w++)if(f<=e.getCapacity(w,p,y))return w}function c(y,f){return r.getCharCountIndicator(y,f)+4}function d(y,f){let p=0;return y.forEach(function(w){const B=c(w.mode,f);p+=B+w.getBitsLength()}),p}function x(y,f){for(let p=1;p<=40;p++)if(d(y,p)<=e.getCapacity(p,f,r.MIXED))return p}e.from=function(f,p){return o.isValid(f)?parseInt(f,10):p},e.getCapacity=function(f,p,w){if(!o.isValid(f))throw new Error("Invalid QR Code version");typeof w>"u"&&(w=r.BYTE);const B=t.getSymbolTotalCodewords(f),h=s.getTotalCodewordsCount(f,p),b=(B-h)*8;if(w===r.MIXED)return b;const g=b-c(w,f);switch(w){case r.NUMERIC:return Math.floor(g/10*3);case r.ALPHANUMERIC:return Math.floor(g/11*2);case r.KANJI:return Math.floor(g/13);case r.BYTE:default:return Math.floor(g/8)}},e.getBestVersionForData=function(f,p){let w;const B=n.from(p,n.M);if(Array.isArray(f)){if(f.length>1)return x(f,B);if(f.length===0)return 1;w=f[0]}else w=f;return a(w.mode,w.getLength(),B)},e.getEncodedBits=function(f){if(!o.isValid(f)||f<7)throw new Error("Invalid QR Code version");let p=f<<12;for(;t.getBCHDigit(p)-l>=0;)p^=i<=0;)r^=Ie<0&&(n=this.data.substr(s),r=parseInt(n,10),t.put(r,o*3+1))};var We=D;const Ze=R,te=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function F(e){this.mode=Ze.ALPHANUMERIC,this.data=e}F.getBitsLength=function(t){return 11*Math.floor(t/2)+6*(t%2)};F.prototype.getLength=function(){return this.data.length};F.prototype.getBitsLength=function(){return F.getBitsLength(this.data.length)};F.prototype.write=function(t){let s;for(s=0;s+2<=this.data.length;s+=2){let n=te.indexOf(this.data[s])*45;n+=te.indexOf(this.data[s+1]),t.put(n,11)}this.data.length%2&&t.put(te.indexOf(this.data[s]),6)};var Xe=F;const et=R;function U(e){this.mode=et.BYTE,typeof e=="string"?this.data=new TextEncoder().encode(e):this.data=new Uint8Array(e)}U.getBitsLength=function(t){return t*8};U.prototype.getLength=function(){return this.data.length};U.prototype.getBitsLength=function(){return U.getBitsLength(this.data.length)};U.prototype.write=function(e){for(let t=0,s=this.data.length;t=33088&&s<=40956)s-=33088;else if(s>=57408&&s<=60351)s-=49472;else throw new Error("Invalid SJIS character: "+this.data[t]+` Make sure your charset is UTF-8`);s=(s>>>8&255)*192+(s&255),e.put(s,13)}};var ot=z,Me={exports:{}};(function(e){var t={single_source_shortest_paths:function(s,n,r){var o={},i={};i[n]=0;var l=t.PriorityQueue.make();l.push(n,0);for(var a,c,d,x,y,f,p,w,B;!l.empty();){a=l.pop(),c=a.value,x=a.cost,y=s[c]||{};for(d in y)y.hasOwnProperty(d)&&(f=y[d],p=x+f,w=i[d],B=typeof i[d]>"u",(B||w>p)&&(i[d]=p,l.push(d,p),o[d]=c))}if(typeof r<"u"&&typeof i[r]>"u"){var h=["Could not find a path from ",n," to ",r,"."].join("");throw new Error(h)}return o},extract_shortest_path_from_predecessor_list:function(s,n){for(var r=[],o=n;o;)r.push(o),s[o],o=s[o];return r.reverse(),r},find_path:function(s,n,r){var o=t.single_source_shortest_paths(s,n,r);return t.extract_shortest_path_from_predecessor_list(o,r)},PriorityQueue:{make:function(s){var n=t.PriorityQueue,r={},o;s=s||{};for(o in n)n.hasOwnProperty(o)&&(r[o]=n[o]);return r.queue=[],r.sorter=s.sorter||n.default_sorter,r},default_sorter:function(s,n){return s.cost-n.cost},push:function(s,n){var r={value:s,cost:n};this.queue.push(r),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return this.queue.length===0}}};e.exports=t})(Me);var st=Me.exports;(function(e){const t=R,s=We,n=Xe,r=tt,o=ot,i=_,l=S,a=st;function c(h){return unescape(encodeURIComponent(h)).length}function d(h,b,g){const m=[];let C;for(;(C=h.exec(g))!==null;)m.push({data:C[0],index:C.index,mode:b,length:C[0].length});return m}function x(h){const b=d(i.NUMERIC,t.NUMERIC,h),g=d(i.ALPHANUMERIC,t.ALPHANUMERIC,h);let m,C;return l.isKanjiModeEnabled()?(m=d(i.BYTE,t.BYTE,h),C=d(i.KANJI,t.KANJI,h)):(m=d(i.BYTE_KANJI,t.BYTE,h),C=[]),b.concat(g,m,C).sort(function(A,k){return A.index-k.index}).map(function(A){return{data:A.data,mode:A.mode,length:A.length}})}function y(h,b){switch(b){case t.NUMERIC:return s.getBitsLength(h);case t.ALPHANUMERIC:return n.getBitsLength(h);case t.KANJI:return o.getBitsLength(h);case t.BYTE:return r.getBitsLength(h)}}function f(h){return h.reduce(function(b,g){const m=b.length-1>=0?b[b.length-1]:null;return m&&m.mode===g.mode?(b[b.length-1].data+=g.data,b):(b.push(g),b)},[])}function p(h){const b=[];for(let g=0;g=0&&l<=6&&(a===0||a===6)||a>=0&&a<=6&&(l===0||l===6)||l>=2&&l<=4&&a>=2&&a<=4?e.set(o+l,i+a,!0,!0):e.set(o+l,i+a,!1,!0))}}function gt(e){const t=e.size;for(let s=8;s>l&1)===1,e.set(r,o,i,!0),e.set(o,r,i,!0)}function oe(e,t,s){const n=e.size,r=ct.getEncodedBits(t,s);let o,i;for(o=0;o<15;o++)i=(r>>o&1)===1,o<6?e.set(o,8,i,!0):o<8?e.set(o+1,8,i,!0):e.set(n-15+o,8,i,!0),o<8?e.set(8,n-o-1,i,!0):o<9?e.set(8,15-o-1+1,i,!0):e.set(8,15-o-1,i,!0);e.set(n-8,8,1,!0)}function wt(e,t){const s=e.size;let n=-1,r=s-1,o=7,i=0;for(let l=s-1;l>0;l-=2)for(l===6&&l--;;){for(let a=0;a<2;a++)if(!e.isReserved(r,l-a)){let c=!1;i>>o&1)===1),e.set(r,l-a,c),o--,o===-1&&(i++,o=7)}if(r+=n,r<0||s<=r){r-=n,n=-n;break}}}function pt(e,t,s){const n=new it;s.forEach(function(a){n.put(a.mode.bit,4),n.put(a.getLength(),ft.getCharCountIndicator(a.mode,e)),a.write(n)});const r=ee.getSymbolTotalCodewords(e),o=le.getTotalCodewordsCount(e,t),i=(r-o)*8;for(n.getLengthInBits()+4<=i&&n.put(0,4);n.getLengthInBits()%8!==0;)n.putBit(0);const l=(i-n.getLengthInBits())/8;for(let a=0;a{c.get("/admin-users").then(w),c.get("/permissions/catalog").then(S),(h("permission_groups.manage")||h("users.manage"))&&c.get("/permission-groups").then(B)};n.useEffect(x,[]);const E=t=>{var i;j(t.id),k(t.is_primary);const s={username:t.username,password:"",is_super_admin:t.is_super_admin,permissions:t.permissions,group_ids:t.groups.map(P=>P.id)};d(s),y(s),(i=v.current)==null||i.scrollIntoView({behavior:"smooth",block:"start"})},p=()=>{j(null),k(!1),d(o),y(o)},A=t=>{d(s=>({...s,permissions:s.permissions.includes(t)?s.permissions.filter(i=>i!==t):[...s.permissions,t]}))},C=t=>{d(s=>({...s,group_ids:s.group_ids.includes(t)?s.group_ids.filter(i=>i!==t):[...s.group_ids,t]}))},D=async t=>{t.preventDefault(),u("");try{if(l)await c.put(`/admin-users/${l}`,r);else{if(r.password.length<8){u("Passwort muss mindestens 8 Zeichen lang sein");return}await c.post("/admin-users",r)}m.success(l?"Benutzer gespeichert.":`Benutzer „${r.username}“ angelegt.`),p(),x()}catch(s){u(s.message)}},F=async t=>{if(confirm("Diesen Benutzer wirklich löschen?"))try{await c.delete(`/admin-users/${t}`),l===t&&p(),m.success("Benutzer gelöscht."),x()}catch(s){m.error(`Löschen fehlgeschlagen: ${s.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Benutzer"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Jeder Mitarbeiter bekommt ein eigenes Konto mit genau den Rechten, die er braucht."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Benutzername"}),e.jsx("th",{className:"px-4 py-2",children:"Rolle"}),e.jsx("th",{className:"px-4 py-2",children:"Berechtigungsgruppen"}),e.jsx("th",{className:"px-4 py-2",children:"Zuletzt aktiv"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[g.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2 font-medium text-neutral-800 dark:text-neutral-100",children:[t.username,t.id===(a==null?void 0:a.id)&&e.jsx("span",{className:"ml-1 text-xs text-neutral-400",children:"(du)"}),t.is_primary&&e.jsx("span",{className:"ml-1 text-xs text-neutral-400",children:"(Erst-Administrator)"})]}),e.jsx("td",{className:"px-4 py-2",children:t.is_super_admin?e.jsx("span",{className:"rounded-full bg-brand-100 px-2 py-0.5 text-xs font-medium text-brand-700 dark:bg-brand-900/40 dark:text-brand-300",children:"Super-Admin"}):e.jsxs("span",{className:"text-neutral-500 dark:text-neutral-400",children:[t.permissions.length," Einzelrechte"]})}),e.jsx("td",{className:"px-4 py-2",children:e.jsxs("div",{className:"flex flex-wrap gap-1",children:[t.groups.map(s=>e.jsx("span",{className:"rounded-full bg-neutral-100 px-2 py-0.5 text-xs text-neutral-600 dark:bg-neutral-800 dark:text-neutral-300",children:s.name},s.id)),t.groups.length===0&&"–"]})}),e.jsx("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:$(t.last_active_at)}),e.jsxs("td",{className:"whitespace-nowrap px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>E(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),t.id!==(a==null?void 0:a.id)&&!t.is_primary&&e.jsx("button",{onClick:()=>F(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),g.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:5,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Benutzer angelegt."})})]})]})})]}),e.jsxs("form",{ref:v,onSubmit:D,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:l?"Benutzer bearbeiten":"Neuer Benutzer"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername *"}),e.jsx("input",{required:!0,value:r.username,onChange:t=>d({...r,username:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Passwort ",l?"(leer lassen = unverändert)":"*"]}),e.jsx("input",{type:"password",required:!l,value:r.password,onChange:t=>d({...r,password:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),(a==null?void 0:a.is_super_admin)&&e.jsxs("div",{children:[e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.is_super_admin,disabled:N,onChange:t=>d({...r,is_super_admin:t.target.checked}),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500 disabled:opacity-50"}),"Super-Admin (hat automatisch alle Rechte)"]}),N&&e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Der Erst-Administrator behält immer den Super-Admin-Status."})]}),!r.is_super_admin&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Einzelne Berechtigungen"}),e.jsx("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:_.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.permissions.includes(t.key),onChange:()=>A(t.key),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.label]},t.key))})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Berechtigungsgruppen"}),e.jsxs("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:[b.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.group_ids.includes(t.id),onChange:()=>C(t.id),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.name]},t.id)),b.length===0&&e.jsx("p",{className:"text-sm text-neutral-400",children:"Noch keine Berechtigungsgruppen angelegt."})]})]})]}),f&&e.jsx("p",{className:"text-sm text-red-600",children:f}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:l?"Speichern":"Anlegen"}),l&&e.jsx("button",{type:"button",onClick:p,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{q as default}; +import{h as R,r as n,o as I,p as L,j as e,c}from"./index-Cc1wEeIX.js";const o={username:"",password:"",is_super_admin:!1,permissions:[],group_ids:[]};function $(a){return a?new Date(a.replace(" ","T")).toLocaleString("de-DE",{day:"2-digit",month:"2-digit",year:"numeric",hour:"2-digit",minute:"2-digit"}):"Noch nie"}function q(){const{user:a,hasPermission:h}=R(),[g,w]=n.useState([]),[_,S]=n.useState([]),[b,B]=n.useState([]),[r,d]=n.useState(o),[l,j]=n.useState(null),[N,k]=n.useState(!1),[f,u]=n.useState(""),[z,y]=n.useState(o),v=n.useRef(null),m=I();L(JSON.stringify(r)!==JSON.stringify(z),"admin-users");const x=()=>{c.get("/admin-users").then(w),c.get("/permissions/catalog").then(S),(h("permission_groups.manage")||h("users.manage"))&&c.get("/permission-groups").then(B)};n.useEffect(x,[]);const E=t=>{var i;j(t.id),k(t.is_primary);const s={username:t.username,password:"",is_super_admin:t.is_super_admin,permissions:t.permissions,group_ids:t.groups.map(P=>P.id)};d(s),y(s),(i=v.current)==null||i.scrollIntoView({behavior:"smooth",block:"start"})},p=()=>{j(null),k(!1),d(o),y(o)},A=t=>{d(s=>({...s,permissions:s.permissions.includes(t)?s.permissions.filter(i=>i!==t):[...s.permissions,t]}))},C=t=>{d(s=>({...s,group_ids:s.group_ids.includes(t)?s.group_ids.filter(i=>i!==t):[...s.group_ids,t]}))},D=async t=>{t.preventDefault(),u("");try{if(l)await c.put(`/admin-users/${l}`,r);else{if(r.password.length<8){u("Passwort muss mindestens 8 Zeichen lang sein");return}await c.post("/admin-users",r)}m.success(l?"Benutzer gespeichert.":`Benutzer „${r.username}“ angelegt.`),p(),x()}catch(s){u(s.message)}},F=async t=>{if(confirm("Diesen Benutzer wirklich löschen?"))try{await c.delete(`/admin-users/${t}`),l===t&&p(),m.success("Benutzer gelöscht."),x()}catch(s){m.error(`Löschen fehlgeschlagen: ${s.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Benutzer"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Jeder Mitarbeiter bekommt ein eigenes Konto mit genau den Rechten, die er braucht."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Benutzername"}),e.jsx("th",{className:"px-4 py-2",children:"Rolle"}),e.jsx("th",{className:"px-4 py-2",children:"Berechtigungsgruppen"}),e.jsx("th",{className:"px-4 py-2",children:"Zuletzt aktiv"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[g.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2 font-medium text-neutral-800 dark:text-neutral-100",children:[t.username,t.id===(a==null?void 0:a.id)&&e.jsx("span",{className:"ml-1 text-xs text-neutral-400",children:"(du)"}),t.is_primary&&e.jsx("span",{className:"ml-1 text-xs text-neutral-400",children:"(Erst-Administrator)"})]}),e.jsx("td",{className:"px-4 py-2",children:t.is_super_admin?e.jsx("span",{className:"rounded-full bg-brand-100 px-2 py-0.5 text-xs font-medium text-brand-700 dark:bg-brand-900/40 dark:text-brand-300",children:"Super-Admin"}):e.jsxs("span",{className:"text-neutral-500 dark:text-neutral-400",children:[t.permissions.length," Einzelrechte"]})}),e.jsx("td",{className:"px-4 py-2",children:e.jsxs("div",{className:"flex flex-wrap gap-1",children:[t.groups.map(s=>e.jsx("span",{className:"rounded-full bg-neutral-100 px-2 py-0.5 text-xs text-neutral-600 dark:bg-neutral-800 dark:text-neutral-300",children:s.name},s.id)),t.groups.length===0&&"–"]})}),e.jsx("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:$(t.last_active_at)}),e.jsxs("td",{className:"whitespace-nowrap px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>E(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),t.id!==(a==null?void 0:a.id)&&!t.is_primary&&e.jsx("button",{onClick:()=>F(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),g.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:5,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Benutzer angelegt."})})]})]})})]}),e.jsxs("form",{ref:v,onSubmit:D,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:l?"Benutzer bearbeiten":"Neuer Benutzer"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername *"}),e.jsx("input",{required:!0,value:r.username,onChange:t=>d({...r,username:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Passwort ",l?"(leer lassen = unverändert)":"*"]}),e.jsx("input",{type:"password",required:!l,value:r.password,onChange:t=>d({...r,password:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),(a==null?void 0:a.is_super_admin)&&e.jsxs("div",{children:[e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.is_super_admin,disabled:N,onChange:t=>d({...r,is_super_admin:t.target.checked}),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500 disabled:opacity-50"}),"Super-Admin (hat automatisch alle Rechte)"]}),N&&e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Der Erst-Administrator behält immer den Super-Admin-Status."})]}),!r.is_super_admin&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Einzelne Berechtigungen"}),e.jsx("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:_.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.permissions.includes(t.key),onChange:()=>A(t.key),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.label]},t.key))})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Berechtigungsgruppen"}),e.jsxs("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:[b.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.group_ids.includes(t.id),onChange:()=>C(t.id),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.name]},t.id)),b.length===0&&e.jsx("p",{className:"text-sm text-neutral-400",children:"Noch keine Berechtigungsgruppen angelegt."})]})]})]}),f&&e.jsx("p",{className:"text-sm text-red-600",children:f}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:l?"Speichern":"Anlegen"}),l&&e.jsx("button",{type:"button",onClick:p,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{q as default}; diff --git a/hifi/assets/Brands-DKoTUwWY.js b/hifi/assets/Brands-CdXOB29N.js similarity index 92% rename from hifi/assets/Brands-DKoTUwWY.js rename to hifi/assets/Brands-CdXOB29N.js index a71b0a7..f33bfa9 100644 --- a/hifi/assets/Brands-DKoTUwWY.js +++ b/hifi/assets/Brands-CdXOB29N.js @@ -1 +1 @@ -import{o as M,r as n,p as R,j as e,L as F,c as h}from"./index-Tg8iNBwT.js";import{I as B}from"./ImageUploadField-Ds8_wHup.js";import{T as C}from"./TextStyleWidget-By2wExOQ.js";import{S as E,s as I}from"./SortableList-DRJ1jYgo.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const u={name:"",image_path:"",sort_order:0};function O(){const i=M(),[d,o]=n.useState([]),[s,c]=n.useState(u),[y,f]=n.useState(u),[a,k]=n.useState(null),[j,x]=n.useState(""),p=n.useRef(null);R(JSON.stringify(s)!==JSON.stringify(y),"brands");const g=()=>h.get("/brands").then(o);n.useEffect(()=>{g()},[]);const w=t=>{const r={name:t.name,image_path:t.image_path||"",sort_order:t.sort_order};k(t.id),c(r),f(r),x(""),requestAnimationFrame(()=>{var l,m,N;(l=p.current)==null||l.scrollIntoView({behavior:"smooth",block:"start"}),(N=(m=p.current)==null?void 0:m.querySelector("input"))==null||N.focus({preventScroll:!0})})},b=()=>{k(null),c(u),f(u)},v=async t=>{t.preventDefault(),x("");try{if(a)await h.put(`/brands/${a}`,s);else{const r=d.reduce((l,m)=>Math.max(l,Number(m.sort_order)||0),0)+10;await h.post("/brands",{...s,sort_order:r})}i.success(a?"Marke gespeichert.":"Marke angelegt."),b(),g()}catch(r){x(r.message)}},S=async t=>{if(confirm("Marke inkl. aller Modelle/Pakete/Produkte wirklich löschen?"))try{await h.delete(`/brands/${t}`),a===t&&b(),i.success("Marke gelöscht."),g()}catch(r){i.error(`Löschen fehlgeschlagen: ${r.message}`)}},_=async t=>{const r=d;o(t);try{o(await I("brands",t)),i.success("Reihenfolge gespeichert.")}catch(l){o(r),i.error(`Reihenfolge konnte nicht gespeichert werden: ${l.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Marken"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Reihenfolge am Griff links per Ziehen ändern – so erscheinen die Marken auf der Website."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Bild"}),e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(E,{items:d,onReorder:_,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.image_path?e.jsx("img",{src:t.image_path,alt:"",className:"h-10 w-10 rounded-md object-cover"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:e.jsx(F,{to:`/fahrzeuge/${t.slug}`,target:"_blank",className:"hover:text-brand-500",children:t.name})}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>w(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>S(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),d.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:4,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Marken angelegt."})})})]})})]}),e.jsxs("form",{ref:p,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:a?"Marke bearbeiten":"Neue Marke"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:s.name,onChange:t=>c({...s,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),a&&e.jsx(C,{fieldKey:`brands.${a}.name`,previewText:s.name||"Beispieltext"})]}),e.jsx(B,{value:s.image_path,onChange:t=>c({...s,image_path:t}),label:"Bild (optional)"}),j&&e.jsx("p",{className:"text-sm text-red-600",children:j}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:a?"Speichern":"Anlegen"}),a&&e.jsx("button",{type:"button",onClick:b,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{O as default}; +import{o as M,r as n,p as R,j as e,L as F,c as h}from"./index-Cc1wEeIX.js";import{I as B}from"./ImageUploadField-DYOhdPMm.js";import{T as C}from"./TextStyleWidget-DH0ih_Iq.js";import{S as E,s as I}from"./SortableList-DIXFCDYS.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const u={name:"",image_path:"",sort_order:0};function O(){const i=M(),[d,o]=n.useState([]),[s,c]=n.useState(u),[y,f]=n.useState(u),[a,k]=n.useState(null),[j,x]=n.useState(""),p=n.useRef(null);R(JSON.stringify(s)!==JSON.stringify(y),"brands");const g=()=>h.get("/brands").then(o);n.useEffect(()=>{g()},[]);const w=t=>{const r={name:t.name,image_path:t.image_path||"",sort_order:t.sort_order};k(t.id),c(r),f(r),x(""),requestAnimationFrame(()=>{var l,m,N;(l=p.current)==null||l.scrollIntoView({behavior:"smooth",block:"start"}),(N=(m=p.current)==null?void 0:m.querySelector("input"))==null||N.focus({preventScroll:!0})})},b=()=>{k(null),c(u),f(u)},v=async t=>{t.preventDefault(),x("");try{if(a)await h.put(`/brands/${a}`,s);else{const r=d.reduce((l,m)=>Math.max(l,Number(m.sort_order)||0),0)+10;await h.post("/brands",{...s,sort_order:r})}i.success(a?"Marke gespeichert.":"Marke angelegt."),b(),g()}catch(r){x(r.message)}},S=async t=>{if(confirm("Marke inkl. aller Modelle/Pakete/Produkte wirklich löschen?"))try{await h.delete(`/brands/${t}`),a===t&&b(),i.success("Marke gelöscht."),g()}catch(r){i.error(`Löschen fehlgeschlagen: ${r.message}`)}},_=async t=>{const r=d;o(t);try{o(await I("brands",t)),i.success("Reihenfolge gespeichert.")}catch(l){o(r),i.error(`Reihenfolge konnte nicht gespeichert werden: ${l.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Marken"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Reihenfolge am Griff links per Ziehen ändern – so erscheinen die Marken auf der Website."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Bild"}),e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(E,{items:d,onReorder:_,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.image_path?e.jsx("img",{src:t.image_path,alt:"",className:"h-10 w-10 rounded-md object-cover"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:e.jsx(F,{to:`/fahrzeuge/${t.slug}`,target:"_blank",className:"hover:text-brand-500",children:t.name})}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>w(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>S(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),d.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:4,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Marken angelegt."})})})]})})]}),e.jsxs("form",{ref:p,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:a?"Marke bearbeiten":"Neue Marke"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:s.name,onChange:t=>c({...s,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),a&&e.jsx(C,{fieldKey:`brands.${a}.name`,previewText:s.name||"Beispieltext"})]}),e.jsx(B,{value:s.image_path,onChange:t=>c({...s,image_path:t}),label:"Bild (optional)"}),j&&e.jsx("p",{className:"text-sm text-red-600",children:j}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:a?"Speichern":"Anlegen"}),a&&e.jsx("button",{type:"button",onClick:b,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{O as default}; diff --git a/hifi/assets/ContactRequests-C9ur1i_c.js b/hifi/assets/ContactRequests-D4KmPFzX.js similarity index 98% rename from hifi/assets/ContactRequests-C9ur1i_c.js rename to hifi/assets/ContactRequests-D4KmPFzX.js index 6b7ee20..6d631b5 100644 --- a/hifi/assets/ContactRequests-C9ur1i_c.js +++ b/hifi/assets/ContactRequests-D4KmPFzX.js @@ -1 +1 @@ -import{h as z,n as _,q as M,r,j as t,c as b}from"./index-Tg8iNBwT.js";import{t as R,m as F,a as K,v as y}from"./contactRequests-Qfsfq7Lb.js";const D=s=>new Intl.NumberFormat("de-DE",{style:"currency",currency:"EUR"}).format(s),S={new:"Neu",in_progress:"In Bearbeitung",done:"Erledigt"},P={new:"bg-brand-100 text-brand-700 dark:bg-brand-900/40 dark:text-brand-300",in_progress:"bg-amber-100 text-amber-700 dark:bg-amber-900/40 dark:text-amber-300",done:"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300"},T=()=>t.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",className:"h-4 w-4",children:t.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 7h16M9 7V5a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2m3 0-.8 12.1a1 1 0 0 1-1 .9H7.8a1 1 0 0 1-1-.9L6 7h12ZM10 11v6M14 11v6"})});function U({request:s,onSaved:u}){const[d,p]=r.useState(s.internal_note||""),[i,l]=r.useState(!1),{toast:m}=_(),x=s.internal_note||"",g=async()=>{if(d!==x){l(!0);try{await b.patch(`/contact/${s.id}`,{internal_note:d}),u(s.id,{internal_note:d}),m.success("Notiz gespeichert.")}catch(o){m.error(`Notiz nicht gespeichert: ${o.message}`)}finally{l(!1)}}};return t.jsxs("div",{className:"mt-3",children:[t.jsxs("label",{className:"mb-1 block text-xs font-semibold uppercase tracking-wide text-neutral-400",htmlFor:`note-${s.id}`,children:["Interne Notiz ",i&&t.jsx("span",{className:"normal-case",children:"– speichert…"})]}),t.jsx("textarea",{id:`note-${s.id}`,rows:2,value:d,onChange:o=>p(o.target.value),onBlur:g,placeholder:"Nur für dein Team sichtbar, z. B. „Angebot geschickt am …“",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})}function H(){const{hasPermission:s}=z(),{toast:u,refreshCounters:d}=_(),[p]=M(),i=p.get("id"),[l,m]=r.useState(null),[x,g]=r.useState(""),[o,A]=r.useState(i?"all":"new"),[j,E]=r.useState(""),f=r.useRef(null),L=()=>b.get("/contact").then(e=>{m(e),g("")}).catch(e=>g(e.message));r.useEffect(()=>{L()},[]),r.useEffect(()=>{i&&l&&f.current&&f.current.scrollIntoView({behavior:"smooth",block:"center"})},[i,l]);const k=(e,a)=>m(n=>n.map(c=>c.id===e?{...c,...a}:c)),$=async(e,a)=>{var c;const n=(c=l.find(v=>v.id===e))==null?void 0:c.status;k(e,{status:a});try{await b.patch(`/contact/${e}`,{status:a}),u.success(`Status: ${S[a]}`),d()}catch(v){k(e,{status:n}),u.error(`Status nicht geändert: ${v.message}`)}},C=async e=>{if(confirm("Diese Kontaktanfrage wirklich unwiderruflich löschen?"))try{await b.delete(`/contact/${e}`),m(a=>a.filter(n=>n.id!==e)),u.success("Anfrage gelöscht."),d()}catch(a){u.error(`Löschen fehlgeschlagen: ${a.message}`)}},h=l||[],B=r.useMemo(()=>({all:h.length,new:h.filter(e=>e.status==="new").length,in_progress:h.filter(e=>e.status==="in_progress").length,done:h.filter(e=>e.status==="done").length}),[h]),w=j.trim().toLowerCase(),N=h.filter(e=>o==="all"||e.status===o).filter(e=>!w||[e.name,e.email,e.phone,e.brand_name,e.model_name,e.package_name,e.message,e.internal_note].filter(Boolean).some(a=>String(a).toLowerCase().includes(w))),I=[{value:"new",label:"Neu"},{value:"in_progress",label:"In Bearbeitung"},{value:"done",label:"Erledigt"},{value:"all",label:"Alle"}];return t.jsxs("div",{children:[t.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Anfragen"}),t.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Anfragen aus dem Kontaktformular. Mit „Antworten“ öffnet sich dein E-Mail-Programm mit fertigem Betreff. Setze den Status auf „Erledigt“, wenn alles geklärt ist."}),t.jsxs("div",{className:"mb-5 flex flex-wrap items-center gap-2",children:[I.map(e=>t.jsxs("button",{onClick:()=>A(e.value),className:`rounded-full px-4 py-1.5 text-sm font-medium transition ${o===e.value?"bg-brand-500 text-white":"bg-neutral-100 text-neutral-600 hover:bg-neutral-200 dark:bg-neutral-800 dark:text-neutral-300 dark:hover:bg-neutral-700"}`,children:[e.label," (",B[e.value],")"]},e.value)),t.jsx("input",{type:"search",value:j,onChange:e=>E(e.target.value),placeholder:"Suchen: Name, Fahrzeug, Text…",className:"ml-auto w-full rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900 sm:w-64"})]}),x&&t.jsxs("p",{className:"mb-4 text-sm text-red-600",children:["Anfragen konnten nicht geladen werden: ",x]}),l===null&&!x&&t.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),t.jsxs("div",{className:"space-y-3",children:[N.map(e=>{var a;return t.jsxs("div",{ref:String(e.id)===i?f:void 0,className:`rounded-xl border bg-white p-4 dark:bg-neutral-900 ${String(e.id)===i?"border-brand-500 ring-2 ring-brand-500/30":"border-neutral-200 dark:border-neutral-800"}`,children:[t.jsxs("div",{className:"mb-2 flex flex-wrap items-start justify-between gap-2",children:[t.jsxs("div",{className:"min-w-0",children:[t.jsx("p",{className:"font-semibold text-neutral-800 dark:text-neutral-100",children:e.name}),t.jsxs("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:[e.email,e.phone?` · ${e.phone}`:""]}),e.vin&&t.jsxs("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:["FIN: ",t.jsx("span",{className:"font-mono",children:e.vin})]}),t.jsx("p",{className:"text-xs text-neutral-400",title:new Date(e.created_at.replace(" ","T")).toLocaleString("de-DE"),children:R(e.created_at)})]}),t.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[t.jsx("a",{href:F(e),className:"rounded-md bg-brand-500 px-3 py-1.5 text-sm font-semibold text-white hover:bg-brand-600",children:"Antworten"}),e.phone&&t.jsx("a",{href:K(e.phone),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:"Anrufen"}),t.jsx("select",{value:e.status,onChange:n=>$(e.id,n.target.value),"aria-label":"Status",className:`rounded-full border-0 px-3 py-1.5 text-xs font-medium ${P[e.status]}`,children:Object.entries(S).map(([n,c])=>t.jsx("option",{value:n,children:c},n))}),s("contact.delete")&&t.jsx("button",{onClick:()=>C(e.id),"aria-label":"Anfrage löschen",title:"Anfrage löschen",className:"rounded-md p-1.5 text-neutral-400 hover:bg-red-50 hover:text-red-600 dark:hover:bg-red-900/20",children:t.jsx(T,{})})]})]}),(y(e)||e.product_name)&&t.jsx("p",{className:"mb-2 text-sm text-neutral-500 dark:text-neutral-400",children:[y(e),e.product_name].filter(Boolean).join(" · ")}),((a=e.selected_upgrades)==null?void 0:a.length)>0&&t.jsxs("div",{className:"mb-2 rounded-md bg-brand-50 p-2 text-sm text-brand-800 dark:bg-brand-900/20 dark:text-brand-200",children:[t.jsx("p",{className:"font-semibold",children:"Gewünschte Upgrades:"}),t.jsx("ul",{className:"list-disc pl-5",children:e.selected_upgrades.map(n=>t.jsxs("li",{children:[n.name," – ",D(n.price)]},n.id))})]}),e.message&&t.jsx("p",{className:"whitespace-pre-line text-sm text-neutral-700 dark:text-neutral-300",children:e.message}),t.jsx(U,{request:e,onSaved:k})]},e.id)}),l!==null&&N.length===0&&t.jsx("p",{className:"text-neutral-400",children:w?"Keine Anfrage passt zur Suche.":o==="new"?"Keine neuen Anfragen – alles beantwortet.":o==="all"?"Noch keine Kontaktanfragen eingegangen.":"Keine Anfragen mit diesem Status."})]})]})}export{H as default}; +import{h as z,n as _,q as M,r,j as t,c as b}from"./index-Cc1wEeIX.js";import{t as R,m as F,a as K,v as y}from"./contactRequests-Qfsfq7Lb.js";const D=s=>new Intl.NumberFormat("de-DE",{style:"currency",currency:"EUR"}).format(s),S={new:"Neu",in_progress:"In Bearbeitung",done:"Erledigt"},P={new:"bg-brand-100 text-brand-700 dark:bg-brand-900/40 dark:text-brand-300",in_progress:"bg-amber-100 text-amber-700 dark:bg-amber-900/40 dark:text-amber-300",done:"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300"},T=()=>t.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",className:"h-4 w-4",children:t.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 7h16M9 7V5a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2m3 0-.8 12.1a1 1 0 0 1-1 .9H7.8a1 1 0 0 1-1-.9L6 7h12ZM10 11v6M14 11v6"})});function U({request:s,onSaved:u}){const[d,p]=r.useState(s.internal_note||""),[i,l]=r.useState(!1),{toast:m}=_(),x=s.internal_note||"",g=async()=>{if(d!==x){l(!0);try{await b.patch(`/contact/${s.id}`,{internal_note:d}),u(s.id,{internal_note:d}),m.success("Notiz gespeichert.")}catch(o){m.error(`Notiz nicht gespeichert: ${o.message}`)}finally{l(!1)}}};return t.jsxs("div",{className:"mt-3",children:[t.jsxs("label",{className:"mb-1 block text-xs font-semibold uppercase tracking-wide text-neutral-400",htmlFor:`note-${s.id}`,children:["Interne Notiz ",i&&t.jsx("span",{className:"normal-case",children:"– speichert…"})]}),t.jsx("textarea",{id:`note-${s.id}`,rows:2,value:d,onChange:o=>p(o.target.value),onBlur:g,placeholder:"Nur für dein Team sichtbar, z. B. „Angebot geschickt am …“",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})}function H(){const{hasPermission:s}=z(),{toast:u,refreshCounters:d}=_(),[p]=M(),i=p.get("id"),[l,m]=r.useState(null),[x,g]=r.useState(""),[o,A]=r.useState(i?"all":"new"),[j,E]=r.useState(""),f=r.useRef(null),L=()=>b.get("/contact").then(e=>{m(e),g("")}).catch(e=>g(e.message));r.useEffect(()=>{L()},[]),r.useEffect(()=>{i&&l&&f.current&&f.current.scrollIntoView({behavior:"smooth",block:"center"})},[i,l]);const k=(e,a)=>m(n=>n.map(c=>c.id===e?{...c,...a}:c)),$=async(e,a)=>{var c;const n=(c=l.find(v=>v.id===e))==null?void 0:c.status;k(e,{status:a});try{await b.patch(`/contact/${e}`,{status:a}),u.success(`Status: ${S[a]}`),d()}catch(v){k(e,{status:n}),u.error(`Status nicht geändert: ${v.message}`)}},C=async e=>{if(confirm("Diese Kontaktanfrage wirklich unwiderruflich löschen?"))try{await b.delete(`/contact/${e}`),m(a=>a.filter(n=>n.id!==e)),u.success("Anfrage gelöscht."),d()}catch(a){u.error(`Löschen fehlgeschlagen: ${a.message}`)}},h=l||[],B=r.useMemo(()=>({all:h.length,new:h.filter(e=>e.status==="new").length,in_progress:h.filter(e=>e.status==="in_progress").length,done:h.filter(e=>e.status==="done").length}),[h]),w=j.trim().toLowerCase(),N=h.filter(e=>o==="all"||e.status===o).filter(e=>!w||[e.name,e.email,e.phone,e.brand_name,e.model_name,e.package_name,e.message,e.internal_note].filter(Boolean).some(a=>String(a).toLowerCase().includes(w))),I=[{value:"new",label:"Neu"},{value:"in_progress",label:"In Bearbeitung"},{value:"done",label:"Erledigt"},{value:"all",label:"Alle"}];return t.jsxs("div",{children:[t.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Anfragen"}),t.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Anfragen aus dem Kontaktformular. Mit „Antworten“ öffnet sich dein E-Mail-Programm mit fertigem Betreff. Setze den Status auf „Erledigt“, wenn alles geklärt ist."}),t.jsxs("div",{className:"mb-5 flex flex-wrap items-center gap-2",children:[I.map(e=>t.jsxs("button",{onClick:()=>A(e.value),className:`rounded-full px-4 py-1.5 text-sm font-medium transition ${o===e.value?"bg-brand-500 text-white":"bg-neutral-100 text-neutral-600 hover:bg-neutral-200 dark:bg-neutral-800 dark:text-neutral-300 dark:hover:bg-neutral-700"}`,children:[e.label," (",B[e.value],")"]},e.value)),t.jsx("input",{type:"search",value:j,onChange:e=>E(e.target.value),placeholder:"Suchen: Name, Fahrzeug, Text…",className:"ml-auto w-full rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900 sm:w-64"})]}),x&&t.jsxs("p",{className:"mb-4 text-sm text-red-600",children:["Anfragen konnten nicht geladen werden: ",x]}),l===null&&!x&&t.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),t.jsxs("div",{className:"space-y-3",children:[N.map(e=>{var a;return t.jsxs("div",{ref:String(e.id)===i?f:void 0,className:`rounded-xl border bg-white p-4 dark:bg-neutral-900 ${String(e.id)===i?"border-brand-500 ring-2 ring-brand-500/30":"border-neutral-200 dark:border-neutral-800"}`,children:[t.jsxs("div",{className:"mb-2 flex flex-wrap items-start justify-between gap-2",children:[t.jsxs("div",{className:"min-w-0",children:[t.jsx("p",{className:"font-semibold text-neutral-800 dark:text-neutral-100",children:e.name}),t.jsxs("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:[e.email,e.phone?` · ${e.phone}`:""]}),e.vin&&t.jsxs("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:["FIN: ",t.jsx("span",{className:"font-mono",children:e.vin})]}),t.jsx("p",{className:"text-xs text-neutral-400",title:new Date(e.created_at.replace(" ","T")).toLocaleString("de-DE"),children:R(e.created_at)})]}),t.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[t.jsx("a",{href:F(e),className:"rounded-md bg-brand-500 px-3 py-1.5 text-sm font-semibold text-white hover:bg-brand-600",children:"Antworten"}),e.phone&&t.jsx("a",{href:K(e.phone),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:"Anrufen"}),t.jsx("select",{value:e.status,onChange:n=>$(e.id,n.target.value),"aria-label":"Status",className:`rounded-full border-0 px-3 py-1.5 text-xs font-medium ${P[e.status]}`,children:Object.entries(S).map(([n,c])=>t.jsx("option",{value:n,children:c},n))}),s("contact.delete")&&t.jsx("button",{onClick:()=>C(e.id),"aria-label":"Anfrage löschen",title:"Anfrage löschen",className:"rounded-md p-1.5 text-neutral-400 hover:bg-red-50 hover:text-red-600 dark:hover:bg-red-900/20",children:t.jsx(T,{})})]})]}),(y(e)||e.product_name)&&t.jsx("p",{className:"mb-2 text-sm text-neutral-500 dark:text-neutral-400",children:[y(e),e.product_name].filter(Boolean).join(" · ")}),((a=e.selected_upgrades)==null?void 0:a.length)>0&&t.jsxs("div",{className:"mb-2 rounded-md bg-brand-50 p-2 text-sm text-brand-800 dark:bg-brand-900/20 dark:text-brand-200",children:[t.jsx("p",{className:"font-semibold",children:"Gewünschte Upgrades:"}),t.jsx("ul",{className:"list-disc pl-5",children:e.selected_upgrades.map(n=>t.jsxs("li",{children:[n.name," – ",D(n.price)]},n.id))})]}),e.message&&t.jsx("p",{className:"whitespace-pre-line text-sm text-neutral-700 dark:text-neutral-300",children:e.message}),t.jsx(U,{request:e,onSaved:k})]},e.id)}),l!==null&&N.length===0&&t.jsx("p",{className:"text-neutral-400",children:w?"Keine Anfrage passt zur Suche.":o==="new"?"Keine neuen Anfragen – alles beantwortet.":o==="all"?"Noch keine Kontaktanfragen eingegangen.":"Keine Anfragen mit diesem Status."})]})]})}export{H as default}; diff --git a/hifi/assets/Dashboard-DNZlgdsq.js b/hifi/assets/Dashboard-Cqfuh4mJ.js similarity index 99% rename from hifi/assets/Dashboard-DNZlgdsq.js rename to hifi/assets/Dashboard-Cqfuh4mJ.js index 52d5f71..2618c42 100644 --- a/hifi/assets/Dashboard-DNZlgdsq.js +++ b/hifi/assets/Dashboard-Cqfuh4mJ.js @@ -1 +1 @@ -import{h as k,r as c,c as x,j as e,L as b,n as j,S as N}from"./index-Tg8iNBwT.js";import{I as w}from"./ImageOptimizer-DiBozBGF.js";import{t as v,v as y,m as A}from"./contactRequests-Qfsfq7Lb.js";function S(){const[a,t]=c.useState(null),[n,m]=c.useState(null),[u,r]=c.useState(""),{toast:h,refreshCounters:f}=j();c.useEffect(()=>{x.get("/site-settings").then(l=>t(l.hidden_areas||[])).catch(l=>r(l.message))},[]);const g=async l=>{const s=l.key,d=!a.includes(s);if(d&&s.startsWith("page.")&&!window.confirm(`„${l.label}“ wirklich für alle Besucher ausblenden? Die Seite verschwindet sofort aus dem Menü.`))return;const o=a,p=d?[...a,s]:a.filter(i=>i!==s);t(p),m(s),r("");try{const i=await x.put("/site-settings/visibility",{hidden_areas:p});t(i.hidden_areas),h.success(d?`„${l.label}“ ist jetzt ausgeblendet.`:`„${l.label}“ ist wieder sichtbar.`),f()}catch(i){t(o),r(i.message),h.error(i.message)}finally{m(null)}};return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Sichtbarkeit der Website"}),e.jsx("p",{className:"mb-5 text-sm text-neutral-500 dark:text-neutral-400",children:"Schalte Bereiche aus, die Besucher gerade nicht sehen sollen. Die Inhalte bleiben gespeichert und sind nach dem Wiedereinschalten sofort wieder da. Änderungen gelten sofort."}),u&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:u}),a===null?!u&&e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsx("div",{className:"grid gap-6 md:grid-cols-2",children:N.map(l=>e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-xs font-semibold uppercase tracking-wide text-neutral-400",children:l.title}),e.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:l.hint}),e.jsx("ul",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:l.areas.map(s=>{const d=!a.includes(s.key);return e.jsxs("li",{className:"flex items-center justify-between gap-3 py-2.5",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:`text-sm font-medium ${d?"text-neutral-800 dark:text-neutral-100":"text-neutral-400 line-through dark:text-neutral-500"}`,children:s.label}),s.note&&e.jsx("p",{className:"text-xs text-neutral-400",children:s.note})]}),e.jsxs("label",{className:"relative inline-flex shrink-0 cursor-pointer items-center",title:d?"Sichtbar – zum Ausblenden klicken":"Ausgeblendet – zum Einblenden klicken",children:[e.jsxs("span",{className:"sr-only",children:[s.label," sichtbar"]}),e.jsx("input",{type:"checkbox",checked:d,disabled:n!==null,onChange:()=>g(s),className:"peer sr-only"}),e.jsx("div",{className:"h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 peer-disabled:opacity-60 dark:bg-neutral-700"}),e.jsx("div",{className:"absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5"})]})]},s.key)})})]},l.title))})]})}function z(){const[a,t]=c.useState(null),[n,m]=c.useState("");if(c.useEffect(()=>{x.get("/analytics/report").then(t).catch(r=>m(r.message))},[]),n)return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsx("p",{className:"text-sm text-red-600",children:n})]});if(!a)return null;if(!a.configured)return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsxs("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:["Noch nicht eingerichtet. Unter"," ",e.jsx(b,{to:"/admin/settings/google",className:"text-brand-600 hover:underline dark:text-brand-400",children:"System → Google-Dienste"})," ","kannst du die Dashboard-Anbindung konfigurieren, um hier Besucherzahlen zu sehen."]})]});const u=Math.max(1,...a.daily.map(r=>r.pageviews));return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsx("p",{className:"mb-5 text-sm text-neutral-500 dark:text-neutral-400",children:"Letzte 7 Tage."}),e.jsxs("div",{className:"mb-6 grid grid-cols-3 gap-4",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-extrabold text-brand-600 dark:text-brand-400",children:a.totals.users}),e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Nutzer"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-extrabold text-brand-600 dark:text-brand-400",children:a.totals.sessions}),e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Sitzungen"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-extrabold text-brand-600 dark:text-brand-400",children:a.totals.pageviews}),e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Seitenaufrufe"})]})]}),a.daily.length>0&&e.jsx("div",{className:"mb-6 flex h-24 items-end gap-1.5",children:a.daily.map(r=>e.jsxs("div",{className:"flex flex-1 flex-col items-center gap-1",children:[e.jsx("div",{className:"w-full rounded-t bg-brand-400 dark:bg-brand-500",style:{height:`${Math.max(4,r.pageviews/u*80)}px`},title:`${r.date}: ${r.pageviews} Seitenaufrufe`}),e.jsxs("span",{className:"text-[10px] text-neutral-400",children:[r.date.slice(6,8),".",r.date.slice(4,6),"."]})]},r.date))}),a.top_pages.length>0&&e.jsxs("div",{children:[e.jsx("p",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-neutral-400",children:"Meistbesuchte Seiten"}),e.jsx("ul",{className:"space-y-1 text-sm",children:a.top_pages.map(r=>e.jsxs("li",{className:"flex items-center justify-between gap-3 text-neutral-700 dark:text-neutral-300",children:[e.jsx("span",{className:"truncate font-mono text-xs",children:r.path}),e.jsx("span",{className:"shrink-0 font-semibold",children:r.pageviews})]},r.path))})]})]})}function _({requests:a}){if(a===null)return null;const t=a.filter(n=>n.status==="new");return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-4 flex flex-wrap items-baseline justify-between gap-2",children:[e.jsxs("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:["Neue Anfragen ",t.length>0&&e.jsx("span",{className:"ml-1 rounded-full bg-red-500 px-2 py-0.5 text-xs font-bold text-white",children:t.length})]}),e.jsx(b,{to:"/admin/contact-requests",className:"text-sm font-medium text-brand-600 hover:underline dark:text-brand-400",children:"Alle Anfragen →"})]}),t.length===0?e.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:"Keine offenen Anfragen – alles beantwortet. 👍"}):e.jsx("ul",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:t.slice(0,5).map(n=>e.jsxs("li",{className:"flex flex-wrap items-center justify-between gap-3 py-3",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsxs("p",{className:"font-medium text-neutral-900 dark:text-white",children:[n.name," ",e.jsxs("span",{className:"text-xs font-normal text-neutral-400",children:["· ",v(n.created_at)]})]}),e.jsx("p",{className:"truncate text-sm text-neutral-500 dark:text-neutral-400",children:y(n)||(n.message?n.message.slice(0,80):"Allgemeine Anfrage")})]}),e.jsxs("div",{className:"flex shrink-0 gap-2",children:[e.jsx("a",{href:A(n),className:"rounded-md bg-brand-500 px-3 py-1.5 text-sm font-semibold text-white hover:bg-brand-600",children:"Antworten"}),e.jsx(b,{to:`/admin/contact-requests?id=${n.id}`,className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:"Öffnen"})]})]},n.id))})]})}function W({hasPermission:a}){const t=[{to:"/admin/packages",label:"Pakete bearbeiten",show:a("packages.manage")},{to:"/admin/gallery-projects",label:"Galerie-Fotos hochladen",show:a("gallery.manage")},{to:"/admin/home-sections",label:"Startseiten-Texte ändern",show:a("content.manage")},{to:"/admin/settings/company",label:"Öffnungszeiten & Kontakt",show:a("settings.manage")},{to:"/admin/settings/maintenance",label:"Wartungsmodus",show:a("settings.manage")}].filter(n=>n.show);return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-3 font-semibold text-neutral-900 dark:text-white",children:"Schnellzugriff"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[t.map(n=>e.jsx(b,{to:n.to,className:"rounded-md border border-neutral-300 px-3 py-2 text-sm font-medium text-neutral-700 hover:border-brand-500 hover:text-brand-600 dark:border-neutral-700 dark:text-neutral-200",children:n.label},n.to)),e.jsx("a",{href:"/",target:"_blank",rel:"noopener noreferrer",className:"rounded-md border border-neutral-300 px-3 py-2 text-sm font-medium text-neutral-700 hover:border-brand-500 hover:text-brand-600 dark:border-neutral-700 dark:text-neutral-200",children:"Website ansehen ↗"})]})]})}function P(){const{user:a,hasPermission:t}=k(),[n,m]=c.useState({}),[u,r]=c.useState(null),[h,f]=c.useState([]);c.useEffect(()=>{t("brands.manage")&&x.get("/brands").then(d=>m(o=>({...o,brands:d.length}))).catch(()=>{}),t("contact.manage")&&x.get("/contact").then(r).catch(()=>r([]));const s=t("models.manage")||t("packages.manage");s&&x.get("/models").then(d=>m(o=>({...o,models:d.length}))).catch(()=>{}),t("packages.manage")&&x.get("/packages").then(d=>m(o=>({...o,packages:d.length}))).catch(()=>{}),s&&t("packages.manage")&&Promise.all([x.get("/models"),x.get("/packages")]).then(([d,o])=>{const p=new Set(o.filter(i=>!i.is_hidden).map(i=>i.car_model_id));f(d.filter(i=>!p.has(i.id)))}).catch(()=>{})},[]);const g=[{key:"brands",label:"Fahrzeugmarken",value:n.brands,to:"/admin/brands",show:t("brands.manage")},{key:"models",label:"Modelle",value:n.models,to:"/admin/models",show:t("models.manage")},{key:"packages",label:"Pakete",value:n.packages,to:"/admin/packages",show:t("packages.manage")}].filter(s=>s.show),l=g.length===0&&!t("contact.manage")&&!t("content.manage")&&!t("settings.manage")&&!t("gallery.manage");return e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{children:[e.jsxs("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:["Willkommen, ",a==null?void 0:a.username,"!"]}),e.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:"Das Wichtigste zuerst: offene Anfragen, Hinweise und die häufigsten Aufgaben."})]}),l&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:"Für deinen Account sind noch keine Bereiche freigeschaltet. Bitte wende dich an einen Administrator."}),t("contact.manage")&&e.jsx(_,{requests:u}),h.length>0&&e.jsxs("section",{className:"rounded-xl border border-amber-200 bg-amber-50 p-5 text-sm text-amber-900 dark:border-amber-900 dark:bg-amber-950/40 dark:text-amber-200",children:[e.jsxs("p",{className:"font-semibold",children:["Hinweis: ",h.length," Modell",h.length===1?"":"e"," ohne sichtbares Paket"]}),e.jsxs("p",{className:"mt-1",children:["Kunden sehen dort nur „noch keine Pakete“ und einen Anfrage-Knopf:"," ",h.slice(0,6).map(s=>`${s.brand_name||""} ${s.name}`.trim()).join(", "),h.length>6?" …":"","."," ",e.jsx(b,{to:"/admin/packages",className:"underline",children:"Pakete anlegen"})]})]}),e.jsx(W,{hasPermission:t}),(t("content.manage")||t("settings.manage"))&&e.jsx(S,{}),t("system.admin")&&e.jsx(z,{}),(t("gallery.manage")||t("settings.manage"))&&e.jsx(w,{compact:!0}),g.length>0&&e.jsxs("section",{children:[e.jsx("p",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-neutral-400",children:"Bestand"}),e.jsx("div",{className:"flex flex-wrap gap-3",children:g.map(s=>e.jsxs(b,{to:s.to,className:"rounded-lg border border-neutral-200 bg-white px-4 py-2 text-sm hover:border-brand-500 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("span",{className:"font-bold text-brand-600 dark:text-brand-400",children:s.value??"…"})," ",e.jsx("span",{className:"text-neutral-600 dark:text-neutral-300",children:s.label})]},s.key))})]})]})}export{P as default}; +import{h as k,r as c,c as x,j as e,L as b,n as j,S as N}from"./index-Cc1wEeIX.js";import{I as w}from"./ImageOptimizer-BWNhyKVh.js";import{t as v,v as y,m as A}from"./contactRequests-Qfsfq7Lb.js";function S(){const[a,t]=c.useState(null),[n,m]=c.useState(null),[u,r]=c.useState(""),{toast:h,refreshCounters:f}=j();c.useEffect(()=>{x.get("/site-settings").then(l=>t(l.hidden_areas||[])).catch(l=>r(l.message))},[]);const g=async l=>{const s=l.key,d=!a.includes(s);if(d&&s.startsWith("page.")&&!window.confirm(`„${l.label}“ wirklich für alle Besucher ausblenden? Die Seite verschwindet sofort aus dem Menü.`))return;const o=a,p=d?[...a,s]:a.filter(i=>i!==s);t(p),m(s),r("");try{const i=await x.put("/site-settings/visibility",{hidden_areas:p});t(i.hidden_areas),h.success(d?`„${l.label}“ ist jetzt ausgeblendet.`:`„${l.label}“ ist wieder sichtbar.`),f()}catch(i){t(o),r(i.message),h.error(i.message)}finally{m(null)}};return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Sichtbarkeit der Website"}),e.jsx("p",{className:"mb-5 text-sm text-neutral-500 dark:text-neutral-400",children:"Schalte Bereiche aus, die Besucher gerade nicht sehen sollen. Die Inhalte bleiben gespeichert und sind nach dem Wiedereinschalten sofort wieder da. Änderungen gelten sofort."}),u&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:u}),a===null?!u&&e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsx("div",{className:"grid gap-6 md:grid-cols-2",children:N.map(l=>e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-xs font-semibold uppercase tracking-wide text-neutral-400",children:l.title}),e.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:l.hint}),e.jsx("ul",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:l.areas.map(s=>{const d=!a.includes(s.key);return e.jsxs("li",{className:"flex items-center justify-between gap-3 py-2.5",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:`text-sm font-medium ${d?"text-neutral-800 dark:text-neutral-100":"text-neutral-400 line-through dark:text-neutral-500"}`,children:s.label}),s.note&&e.jsx("p",{className:"text-xs text-neutral-400",children:s.note})]}),e.jsxs("label",{className:"relative inline-flex shrink-0 cursor-pointer items-center",title:d?"Sichtbar – zum Ausblenden klicken":"Ausgeblendet – zum Einblenden klicken",children:[e.jsxs("span",{className:"sr-only",children:[s.label," sichtbar"]}),e.jsx("input",{type:"checkbox",checked:d,disabled:n!==null,onChange:()=>g(s),className:"peer sr-only"}),e.jsx("div",{className:"h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 peer-disabled:opacity-60 dark:bg-neutral-700"}),e.jsx("div",{className:"absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5"})]})]},s.key)})})]},l.title))})]})}function z(){const[a,t]=c.useState(null),[n,m]=c.useState("");if(c.useEffect(()=>{x.get("/analytics/report").then(t).catch(r=>m(r.message))},[]),n)return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsx("p",{className:"text-sm text-red-600",children:n})]});if(!a)return null;if(!a.configured)return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsxs("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:["Noch nicht eingerichtet. Unter"," ",e.jsx(b,{to:"/admin/settings/google",className:"text-brand-600 hover:underline dark:text-brand-400",children:"System → Google-Dienste"})," ","kannst du die Dashboard-Anbindung konfigurieren, um hier Besucherzahlen zu sehen."]})]});const u=Math.max(1,...a.daily.map(r=>r.pageviews));return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsx("p",{className:"mb-5 text-sm text-neutral-500 dark:text-neutral-400",children:"Letzte 7 Tage."}),e.jsxs("div",{className:"mb-6 grid grid-cols-3 gap-4",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-extrabold text-brand-600 dark:text-brand-400",children:a.totals.users}),e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Nutzer"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-extrabold text-brand-600 dark:text-brand-400",children:a.totals.sessions}),e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Sitzungen"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-2xl font-extrabold text-brand-600 dark:text-brand-400",children:a.totals.pageviews}),e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Seitenaufrufe"})]})]}),a.daily.length>0&&e.jsx("div",{className:"mb-6 flex h-24 items-end gap-1.5",children:a.daily.map(r=>e.jsxs("div",{className:"flex flex-1 flex-col items-center gap-1",children:[e.jsx("div",{className:"w-full rounded-t bg-brand-400 dark:bg-brand-500",style:{height:`${Math.max(4,r.pageviews/u*80)}px`},title:`${r.date}: ${r.pageviews} Seitenaufrufe`}),e.jsxs("span",{className:"text-[10px] text-neutral-400",children:[r.date.slice(6,8),".",r.date.slice(4,6),"."]})]},r.date))}),a.top_pages.length>0&&e.jsxs("div",{children:[e.jsx("p",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-neutral-400",children:"Meistbesuchte Seiten"}),e.jsx("ul",{className:"space-y-1 text-sm",children:a.top_pages.map(r=>e.jsxs("li",{className:"flex items-center justify-between gap-3 text-neutral-700 dark:text-neutral-300",children:[e.jsx("span",{className:"truncate font-mono text-xs",children:r.path}),e.jsx("span",{className:"shrink-0 font-semibold",children:r.pageviews})]},r.path))})]})]})}function _({requests:a}){if(a===null)return null;const t=a.filter(n=>n.status==="new");return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-4 flex flex-wrap items-baseline justify-between gap-2",children:[e.jsxs("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:["Neue Anfragen ",t.length>0&&e.jsx("span",{className:"ml-1 rounded-full bg-red-500 px-2 py-0.5 text-xs font-bold text-white",children:t.length})]}),e.jsx(b,{to:"/admin/contact-requests",className:"text-sm font-medium text-brand-600 hover:underline dark:text-brand-400",children:"Alle Anfragen →"})]}),t.length===0?e.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:"Keine offenen Anfragen – alles beantwortet. 👍"}):e.jsx("ul",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:t.slice(0,5).map(n=>e.jsxs("li",{className:"flex flex-wrap items-center justify-between gap-3 py-3",children:[e.jsxs("div",{className:"min-w-0",children:[e.jsxs("p",{className:"font-medium text-neutral-900 dark:text-white",children:[n.name," ",e.jsxs("span",{className:"text-xs font-normal text-neutral-400",children:["· ",v(n.created_at)]})]}),e.jsx("p",{className:"truncate text-sm text-neutral-500 dark:text-neutral-400",children:y(n)||(n.message?n.message.slice(0,80):"Allgemeine Anfrage")})]}),e.jsxs("div",{className:"flex shrink-0 gap-2",children:[e.jsx("a",{href:A(n),className:"rounded-md bg-brand-500 px-3 py-1.5 text-sm font-semibold text-white hover:bg-brand-600",children:"Antworten"}),e.jsx(b,{to:`/admin/contact-requests?id=${n.id}`,className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:"Öffnen"})]})]},n.id))})]})}function W({hasPermission:a}){const t=[{to:"/admin/packages",label:"Pakete bearbeiten",show:a("packages.manage")},{to:"/admin/gallery-projects",label:"Galerie-Fotos hochladen",show:a("gallery.manage")},{to:"/admin/home-sections",label:"Startseiten-Texte ändern",show:a("content.manage")},{to:"/admin/settings/company",label:"Öffnungszeiten & Kontakt",show:a("settings.manage")},{to:"/admin/settings/maintenance",label:"Wartungsmodus",show:a("settings.manage")}].filter(n=>n.show);return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-3 font-semibold text-neutral-900 dark:text-white",children:"Schnellzugriff"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[t.map(n=>e.jsx(b,{to:n.to,className:"rounded-md border border-neutral-300 px-3 py-2 text-sm font-medium text-neutral-700 hover:border-brand-500 hover:text-brand-600 dark:border-neutral-700 dark:text-neutral-200",children:n.label},n.to)),e.jsx("a",{href:"/",target:"_blank",rel:"noopener noreferrer",className:"rounded-md border border-neutral-300 px-3 py-2 text-sm font-medium text-neutral-700 hover:border-brand-500 hover:text-brand-600 dark:border-neutral-700 dark:text-neutral-200",children:"Website ansehen ↗"})]})]})}function P(){const{user:a,hasPermission:t}=k(),[n,m]=c.useState({}),[u,r]=c.useState(null),[h,f]=c.useState([]);c.useEffect(()=>{t("brands.manage")&&x.get("/brands").then(d=>m(o=>({...o,brands:d.length}))).catch(()=>{}),t("contact.manage")&&x.get("/contact").then(r).catch(()=>r([]));const s=t("models.manage")||t("packages.manage");s&&x.get("/models").then(d=>m(o=>({...o,models:d.length}))).catch(()=>{}),t("packages.manage")&&x.get("/packages").then(d=>m(o=>({...o,packages:d.length}))).catch(()=>{}),s&&t("packages.manage")&&Promise.all([x.get("/models"),x.get("/packages")]).then(([d,o])=>{const p=new Set(o.filter(i=>!i.is_hidden).map(i=>i.car_model_id));f(d.filter(i=>!p.has(i.id)))}).catch(()=>{})},[]);const g=[{key:"brands",label:"Fahrzeugmarken",value:n.brands,to:"/admin/brands",show:t("brands.manage")},{key:"models",label:"Modelle",value:n.models,to:"/admin/models",show:t("models.manage")},{key:"packages",label:"Pakete",value:n.packages,to:"/admin/packages",show:t("packages.manage")}].filter(s=>s.show),l=g.length===0&&!t("contact.manage")&&!t("content.manage")&&!t("settings.manage")&&!t("gallery.manage");return e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{children:[e.jsxs("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:["Willkommen, ",a==null?void 0:a.username,"!"]}),e.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:"Das Wichtigste zuerst: offene Anfragen, Hinweise und die häufigsten Aufgaben."})]}),l&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:"Für deinen Account sind noch keine Bereiche freigeschaltet. Bitte wende dich an einen Administrator."}),t("contact.manage")&&e.jsx(_,{requests:u}),h.length>0&&e.jsxs("section",{className:"rounded-xl border border-amber-200 bg-amber-50 p-5 text-sm text-amber-900 dark:border-amber-900 dark:bg-amber-950/40 dark:text-amber-200",children:[e.jsxs("p",{className:"font-semibold",children:["Hinweis: ",h.length," Modell",h.length===1?"":"e"," ohne sichtbares Paket"]}),e.jsxs("p",{className:"mt-1",children:["Kunden sehen dort nur „noch keine Pakete“ und einen Anfrage-Knopf:"," ",h.slice(0,6).map(s=>`${s.brand_name||""} ${s.name}`.trim()).join(", "),h.length>6?" …":"","."," ",e.jsx(b,{to:"/admin/packages",className:"underline",children:"Pakete anlegen"})]})]}),e.jsx(W,{hasPermission:t}),(t("content.manage")||t("settings.manage"))&&e.jsx(S,{}),t("system.admin")&&e.jsx(z,{}),(t("gallery.manage")||t("settings.manage"))&&e.jsx(w,{compact:!0}),g.length>0&&e.jsxs("section",{children:[e.jsx("p",{className:"mb-2 text-xs font-semibold uppercase tracking-wide text-neutral-400",children:"Bestand"}),e.jsx("div",{className:"flex flex-wrap gap-3",children:g.map(s=>e.jsxs(b,{to:s.to,className:"rounded-lg border border-neutral-200 bg-white px-4 py-2 text-sm hover:border-brand-500 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("span",{className:"font-bold text-brand-600 dark:text-brand-400",children:s.value??"…"})," ",e.jsx("span",{className:"text-neutral-600 dark:text-neutral-300",children:s.label})]},s.key))})]})]})}export{P as default}; diff --git a/hifi/assets/DatabaseSettings-Dd8MgFmo.js b/hifi/assets/DatabaseSettings-CivwQ4EI.js similarity index 98% rename from hifi/assets/DatabaseSettings-Dd8MgFmo.js rename to hifi/assets/DatabaseSettings-CivwQ4EI.js index f6515ed..68602d4 100644 --- a/hifi/assets/DatabaseSettings-Dd8MgFmo.js +++ b/hifi/assets/DatabaseSettings-CivwQ4EI.js @@ -1 +1 @@ -import{r as a,j as e,c as i}from"./index-Tg8iNBwT.js";import{I as T}from"./ImageOptimizer-DiBozBGF.js";function F(){const[r,n]=a.useState({host:"",name:"",user:"",password:"",charset:"utf8mb4"}),[m,b]=a.useState(!1),[y,x]=a.useState(!0),[h,C]=a.useState(!1),[g,p]=a.useState(!1),[k,f]=a.useState(""),[D,j]=a.useState(!1),[s,o]=a.useState(null),[d,w]=a.useState(!0),[v,N]=a.useState(!1),[S,u]=a.useState(null),P=()=>{x(!0),i.get("/settings/database").then(t=>{n({...t.config,password:""}),b(t.has_password)}).finally(()=>x(!1))},c=()=>{w(!0),i.get("/settings/schema-check").then(o).catch(t=>o({ok:!1,error:t.message,tables:[]})).finally(()=>w(!1))};a.useEffect(()=>{P(),c()},[]);const E=async()=>{N(!0),u(null);try{const t=await i.post("/settings/schema-migrate",{});u(t.actions),o(t.report)}catch(t){u(["Fehler: "+t.message])}finally{N(!1)}},z=async t=>{t.preventDefault(),p(!0),f(""),j(!1);try{await i.post("/settings/database",r),j(!0),n(l=>({...l,password:""})),b(!0),c()}catch(l){f(l.message)}finally{p(!1)}};return e.jsxs("div",{className:"max-w-2xl space-y-6",children:[e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Datenbank-Zugangsdaten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Wichtig für einen Umzug auf einen anderen Server/Webspace: Trage hier die Zugangsdaten der dortigen Datenbank ein. Die Verbindung wird vor dem Speichern getestet, damit du dich nicht aussperrst."}),y?e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsxs("form",{onSubmit:z,className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Host *"}),e.jsx("input",{required:!0,value:r.host,onChange:t=>n({...r,host:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Datenbankname *"}),e.jsx("input",{required:!0,value:r.name,onChange:t=>n({...r,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzer *"}),e.jsx("input",{required:!0,value:r.user,onChange:t=>n({...r,user:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Passwort ",m?"(leer lassen = unverändert)":""]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("input",{type:h?"text":"password",value:r.password,onChange:t=>n({...r,password:t.target.value}),placeholder:m?"••••••••":"",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("button",{type:"button",onClick:()=>C(t=>!t),className:"shrink-0 rounded-md border border-neutral-300 px-3 text-sm dark:border-neutral-700",children:h?"Verbergen":"Anzeigen"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Zeichensatz"}),e.jsx("input",{value:r.charset,onChange:t=>n({...r,charset:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),k&&e.jsx("p",{className:"text-sm text-red-600",children:k}),D&&e.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Verbindung erfolgreich getestet und gespeichert."}),e.jsx("button",{type:"submit",disabled:g,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:g?"Teste & speichere…":"Verbindung testen & speichern"})]})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:"Datenbankstruktur"}),!d&&s&&e.jsx("span",{className:`rounded-full px-3 py-1 text-xs font-semibold ${s.ok?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-red-100 text-red-700 dark:bg-red-900/40 dark:text-red-300"}`,children:s.ok?"Datenbank OK":"Datenbank nicht OK"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Prüft, ob diese Datenbank alle Tabellen und Spalten hat, die der aktuelle Code-Stand braucht – wichtig, wenn deine Live-Version auf einem anderen Server einen älteren Stand hat."}),d&&e.jsx("p",{className:"text-sm text-neutral-400",children:"Prüfe…"}),!d&&s&&!s.ok&&e.jsx("ul",{className:"mb-4 space-y-1 rounded-md bg-red-50 p-3 text-sm text-red-800 dark:bg-red-900/20 dark:text-red-300",children:s.tables.filter(t=>!t.ok).map(t=>e.jsx("li",{children:t.exists?e.jsxs(e.Fragment,{children:["Tabelle ",e.jsx("code",{className:"font-mono",children:t.table}),": Spalte(n) fehlen – ",t.missing_columns.join(", ")]}):e.jsxs(e.Fragment,{children:["Tabelle ",e.jsx("code",{className:"font-mono",children:t.table})," fehlt komplett"]})},t.table))}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{onClick:c,disabled:d,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm font-medium hover:bg-neutral-50 disabled:opacity-50 dark:border-neutral-700 dark:hover:bg-neutral-800",children:"Erneut prüfen"}),s&&!s.ok&&e.jsx("button",{onClick:E,disabled:v,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:v?"Aktualisiere…":"Datenbankstruktur aktualisieren"})]}),S&&e.jsx("ul",{className:"mt-3 space-y-1 rounded-md bg-neutral-50 p-3 text-sm text-neutral-700 dark:bg-neutral-800 dark:text-neutral-300",children:S.map((t,l)=>e.jsx("li",{children:t},l))})]}),e.jsx(T,{})]})}export{F as default}; +import{r as a,j as e,c as i}from"./index-Cc1wEeIX.js";import{I as T}from"./ImageOptimizer-BWNhyKVh.js";function F(){const[r,n]=a.useState({host:"",name:"",user:"",password:"",charset:"utf8mb4"}),[m,b]=a.useState(!1),[y,x]=a.useState(!0),[h,C]=a.useState(!1),[g,p]=a.useState(!1),[k,f]=a.useState(""),[D,j]=a.useState(!1),[s,o]=a.useState(null),[d,w]=a.useState(!0),[v,N]=a.useState(!1),[S,u]=a.useState(null),P=()=>{x(!0),i.get("/settings/database").then(t=>{n({...t.config,password:""}),b(t.has_password)}).finally(()=>x(!1))},c=()=>{w(!0),i.get("/settings/schema-check").then(o).catch(t=>o({ok:!1,error:t.message,tables:[]})).finally(()=>w(!1))};a.useEffect(()=>{P(),c()},[]);const E=async()=>{N(!0),u(null);try{const t=await i.post("/settings/schema-migrate",{});u(t.actions),o(t.report)}catch(t){u(["Fehler: "+t.message])}finally{N(!1)}},z=async t=>{t.preventDefault(),p(!0),f(""),j(!1);try{await i.post("/settings/database",r),j(!0),n(l=>({...l,password:""})),b(!0),c()}catch(l){f(l.message)}finally{p(!1)}};return e.jsxs("div",{className:"max-w-2xl space-y-6",children:[e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Datenbank-Zugangsdaten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Wichtig für einen Umzug auf einen anderen Server/Webspace: Trage hier die Zugangsdaten der dortigen Datenbank ein. Die Verbindung wird vor dem Speichern getestet, damit du dich nicht aussperrst."}),y?e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsxs("form",{onSubmit:z,className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Host *"}),e.jsx("input",{required:!0,value:r.host,onChange:t=>n({...r,host:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Datenbankname *"}),e.jsx("input",{required:!0,value:r.name,onChange:t=>n({...r,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzer *"}),e.jsx("input",{required:!0,value:r.user,onChange:t=>n({...r,user:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Passwort ",m?"(leer lassen = unverändert)":""]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("input",{type:h?"text":"password",value:r.password,onChange:t=>n({...r,password:t.target.value}),placeholder:m?"••••••••":"",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("button",{type:"button",onClick:()=>C(t=>!t),className:"shrink-0 rounded-md border border-neutral-300 px-3 text-sm dark:border-neutral-700",children:h?"Verbergen":"Anzeigen"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Zeichensatz"}),e.jsx("input",{value:r.charset,onChange:t=>n({...r,charset:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),k&&e.jsx("p",{className:"text-sm text-red-600",children:k}),D&&e.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Verbindung erfolgreich getestet und gespeichert."}),e.jsx("button",{type:"submit",disabled:g,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:g?"Teste & speichere…":"Verbindung testen & speichern"})]})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:"Datenbankstruktur"}),!d&&s&&e.jsx("span",{className:`rounded-full px-3 py-1 text-xs font-semibold ${s.ok?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-red-100 text-red-700 dark:bg-red-900/40 dark:text-red-300"}`,children:s.ok?"Datenbank OK":"Datenbank nicht OK"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Prüft, ob diese Datenbank alle Tabellen und Spalten hat, die der aktuelle Code-Stand braucht – wichtig, wenn deine Live-Version auf einem anderen Server einen älteren Stand hat."}),d&&e.jsx("p",{className:"text-sm text-neutral-400",children:"Prüfe…"}),!d&&s&&!s.ok&&e.jsx("ul",{className:"mb-4 space-y-1 rounded-md bg-red-50 p-3 text-sm text-red-800 dark:bg-red-900/20 dark:text-red-300",children:s.tables.filter(t=>!t.ok).map(t=>e.jsx("li",{children:t.exists?e.jsxs(e.Fragment,{children:["Tabelle ",e.jsx("code",{className:"font-mono",children:t.table}),": Spalte(n) fehlen – ",t.missing_columns.join(", ")]}):e.jsxs(e.Fragment,{children:["Tabelle ",e.jsx("code",{className:"font-mono",children:t.table})," fehlt komplett"]})},t.table))}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{onClick:c,disabled:d,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm font-medium hover:bg-neutral-50 disabled:opacity-50 dark:border-neutral-700 dark:hover:bg-neutral-800",children:"Erneut prüfen"}),s&&!s.ok&&e.jsx("button",{onClick:E,disabled:v,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:v?"Aktualisiere…":"Datenbankstruktur aktualisieren"})]}),S&&e.jsx("ul",{className:"mt-3 space-y-1 rounded-md bg-neutral-50 p-3 text-sm text-neutral-700 dark:bg-neutral-800 dark:text-neutral-300",children:S.map((t,l)=>e.jsx("li",{children:t},l))})]}),e.jsx(T,{})]})}export{F as default}; diff --git a/hifi/assets/Datenschutz-BkjVpsNF.js b/hifi/assets/Datenschutz-CGepmxse.js similarity index 90% rename from hifi/assets/Datenschutz-BkjVpsNF.js rename to hifi/assets/Datenschutz-CGepmxse.js index 9113fd5..6e9ae0f 100644 --- a/hifi/assets/Datenschutz-BkjVpsNF.js +++ b/hifi/assets/Datenschutz-CGepmxse.js @@ -1 +1 @@ -import{r as a,c as l,b as n,j as e}from"./index-Tg8iNBwT.js";function u(){const[t,s]=a.useState(null);return a.useEffect(()=>{l.get("/legal-pages/datenschutz").then(s).catch(()=>{})},[]),n({title:(t==null?void 0:t.title)||"Datenschutzerklärung",description:"Datenschutzerklärung von HifiPlanet Amorbach gemäß Art. 13 DSGVO.",path:"/datenschutz"}),t?e.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.title}),e.jsx("div",{className:"legal-content text-sm text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:t.body_html}})]}):null}export{u as default}; +import{r as a,c as l,b as n,j as e}from"./index-Cc1wEeIX.js";function u(){const[t,s]=a.useState(null);return a.useEffect(()=>{l.get("/legal-pages/datenschutz").then(s).catch(()=>{})},[]),n({title:(t==null?void 0:t.title)||"Datenschutzerklärung",description:"Datenschutzerklärung von HifiPlanet Amorbach gemäß Art. 13 DSGVO.",path:"/datenschutz"}),t?e.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.title}),e.jsx("div",{className:"legal-content text-sm text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:t.body_html}})]}):null}export{u as default}; diff --git a/hifi/assets/Downloads-MkUPdkz-.js b/hifi/assets/Downloads-BM4-wi1i.js similarity index 96% rename from hifi/assets/Downloads-MkUPdkz-.js rename to hifi/assets/Downloads-BM4-wi1i.js index 281b99a..8abb0db 100644 --- a/hifi/assets/Downloads-MkUPdkz-.js +++ b/hifi/assets/Downloads-BM4-wi1i.js @@ -1 +1 @@ -import{r as n,o as P,p as W,j as e,c as f,A as I}from"./index-Tg8iNBwT.js";import{b as V,A as M}from"./downloads-B9pqFegV.js";import{S as Z,s as T}from"./SortableList-DRJ1jYgo.js";import{V as G}from"./ViewOnSite-CVVA03Ho.js";import{E as H,a as J}from"./eye-Bf2CUjOF.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const v="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",j={title:"",description:"",sort_order:0};function A(d,o,i){return new Promise((c,u)=>{const a=new XMLHttpRequest;a.open("POST",`${I}${d}`),a.withCredentials=!0,a.upload.onprogress=s=>{s.lengthComputable&&i(s.loaded/s.total)},a.onload=()=>{let s=null;try{s=JSON.parse(a.responseText)}catch{}a.status>=200&&a.status<300?c(s):u(new Error((s==null?void 0:s.error)||(a.status===413?"Die Datei ist zu groß für diesen Server.":`Fehler ${a.status}`)))},a.onerror=()=>u(new Error("Netzwerkfehler beim Hochladen")),a.send(o)})}function q(){const[d,o]=n.useState(void 0),[i,c]=n.useState(""),[u,a]=n.useState(!1),[s,x]=n.useState(null);n.useEffect(()=>{f.get("/settings/downloads").then(l=>{o(l.password),c(l.password||"")}).catch(l=>x({kind:"error",text:l.message}))},[]);const m=async l=>{l.preventDefault(),a(!0),x(null);try{const h=await f.put("/settings/downloads",{password:i});o(h.password),c(h.password||""),x({kind:"ok",text:h.password?"Gespeichert – der Bereich ist jetzt geschützt.":"Gespeichert – der Bereich ist jetzt öffentlich."})}catch(h){x({kind:"error",text:h.message})}finally{a(!1)}};return e.jsxs("form",{onSubmit:m,className:"space-y-3 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:"Zugriffsschutz"}),e.jsxs("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:[d===void 0&&"Lädt…",d===null&&"Öffentlich – jeder, der die Seite aufruft, sieht die Dateien.",typeof d=="string"&&"Geschützt – Besucher müssen zuerst das Passwort eingeben."]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Zugangspasswort (leer = öffentlich)"}),e.jsx("input",{value:i,maxLength:100,autoComplete:"off",onChange:l=>c(l.target.value),className:v}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Das Passwort an die Kunden weitergeben – es bleibt hier jederzeit einsehbar. Direkte Links zu einzelnen Dateien funktionieren auch ohne Passwort; wer freigeschaltet hat, könnte sie also weitergeben."})]}),s&&e.jsx("p",{className:`text-sm ${s.kind==="error"?"text-red-600":"text-brand-600 dark:text-brand-400"}`,children:s.text}),e.jsx("button",{type:"submit",disabled:u||d===void 0,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:"Speichern"})]})}function se(){const[d,o]=n.useState([]),[i,c]=n.useState(j),[u,a]=n.useState(null),[s,x]=n.useState(null),[m,l]=n.useState(null),[h,S]=n.useState(!1),[D,g]=n.useState(""),[E,_]=n.useState(null),[C,z]=n.useState(j),k=n.useRef(null),$=n.useRef(null),b=P();W(!!u||JSON.stringify(i)!==JSON.stringify(C),"downloads");const y=()=>f.get("/downloads/manage").then(o);n.useEffect(()=>{y()},[]);const w=()=>{x(null),c(j),z(j),a(null),g(""),k.current&&(k.current.value="")},B=t=>{var p;w(),x(t.id);const r={title:t.title,description:t.description||"",sort_order:t.sort_order};c(r),z(r),(p=$.current)==null||p.scrollIntoView({behavior:"smooth",block:"start"})},F=async t=>{if(t.preventDefault(),!s&&!u){g("Bitte eine Datei auswählen.");return}S(!0),g("");try{if(s){if(await f.put(`/downloads/${s}`,i),u){const r=new FormData;r.append("file",u),l(0),await A(`/downloads/${s}/file`,r,l)}}else{const r=new FormData;r.append("file",u),r.append("title",i.title),r.append("description",i.description),l(0),await A("/downloads",r,l)}b.success(s?"Download gespeichert.":"Datei hochgeladen."),w(),y()}catch(r){g(r.message)}finally{S(!1),l(null)}},L=async t=>{_(t.id);try{const r=await f.patch(`/downloads/${t.id}/visibility`,{is_hidden:!t.is_hidden});o(p=>p.map(N=>N.id===t.id?{...N,is_hidden:r.is_hidden}:N)),b.success(r.is_hidden?`„${t.title}“ ist jetzt ausgeblendet.`:`„${t.title}“ ist wieder sichtbar.`)}catch(r){b.error(`Sichtbarkeit konnte nicht geändert werden: ${r.message}`)}finally{_(null)}},R=async t=>{if(confirm(`"${t.title}" inkl. Datei wirklich löschen?`))try{await f.delete(`/downloads/${t.id}`),s===t.id&&w(),b.success("Download gelöscht."),y()}catch(r){b.error(`Löschen fehlgeschlagen: ${r.message}`)}},O=async t=>{const r=d;o(t);try{o(await T("downloads",t)),b.success("Reihenfolge gespeichert.")}catch(p){o(r),b.error(`Reihenfolge konnte nicht gespeichert werden: ${p.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Downloads"}),e.jsx(G,{to:"/downloads"})]}),e.jsxs("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:["Dateien, die Kunden auf der Seite"," ",e.jsx("a",{href:"/downloads",target:"_blank",rel:"noopener noreferrer",className:"text-brand-600 hover:underline",children:"/downloads"})," ","anhören bzw. herunterladen können, z. B. Songs oder Anleitungen. Der Menüpunkt „Downloads“ erscheint auf der Website automatisch, sobald mindestens eine Datei sichtbar ist. Ohne Zugangspasswort (siehe „Zugriffsschutz“) ist die Seite öffentlich. Reihenfolge am Griff links per Ziehen ändern."]}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Titel / Datei"}),e.jsx("th",{className:"px-4 py-2",children:"Größe"}),e.jsx("th",{className:"px-4 py-2",children:"Website"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(Z,{items:d,onReorder:O,as:"tbody",className:"divide-y divide-neutral-100 bg-white dark:divide-neutral-800 dark:bg-neutral-950",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"px-2 py-2",children:r}),e.jsxs("td",{className:`px-4 py-2 ${t.is_hidden?"opacity-60":""}`,children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:t.title}),e.jsx("a",{href:t.file_path,target:"_blank",rel:"noopener noreferrer",className:"break-all text-xs text-neutral-500 hover:text-brand-600 dark:text-neutral-400",children:t.file_name})]}),e.jsx("td",{className:"whitespace-nowrap px-4 py-2 text-neutral-500 dark:text-neutral-400",children:V(t.file_size)}),e.jsx("td",{className:"px-4 py-2",children:e.jsxs("button",{type:"button",onClick:()=>L(t),disabled:E===t.id,title:t.is_hidden?"Wieder auf der Website anzeigen":"Auf der Website ausblenden",className:`inline-flex items-center gap-1.5 rounded-full border px-2.5 py-1 text-xs font-semibold transition disabled:opacity-50 ${t.is_hidden?"border-amber-300 bg-amber-50 text-amber-800 hover:bg-amber-100 dark:border-amber-700 dark:bg-amber-900/30 dark:text-amber-300":"border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:[t.is_hidden?e.jsx(H,{className:"h-3.5 w-3.5"}):e.jsx(J,{className:"h-3.5 w-3.5"}),t.is_hidden?"Ausgeblendet":"Sichtbar"]})}),e.jsxs("td",{className:"whitespace-nowrap px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>B(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>R(t),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),d.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:"Noch keine Dateien hochgeladen."})]})]}),e.jsxs("div",{className:"h-fit space-y-6",children:[e.jsxs("form",{ref:$,onSubmit:F,className:"scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:s?"Download bearbeiten":"Neue Datei hochladen"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:s?"Datei ersetzen (optional)":"Datei *"}),e.jsx("input",{ref:k,type:"file",accept:M.map(t=>`.${t}`).join(","),onChange:t=>{var r;return a(((r=t.target.files)==null?void 0:r[0])||null)},className:"block w-full text-sm text-neutral-600 file:mr-3 file:rounded-md file:border-0 file:bg-brand-500 file:px-3 file:py-2 file:text-sm file:font-semibold file:text-white hover:file:bg-brand-600 dark:text-neutral-300"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Musik (MP3, WAV, FLAC, …), Videos, PDFs, Bilder, Office-Dokumente oder ZIP-Archive. Andere Dateitypen bitte als ZIP hochladen."})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Titel ",s?"*":"(optional)"]}),e.jsx("input",{required:!!s,value:i.title,maxLength:150,onChange:t=>c({...i,title:t.target.value}),placeholder:s?"":"Leer lassen = Dateiname",className:v})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung (optional)"}),e.jsx("textarea",{rows:3,value:i.description,onChange:t=>c({...i,description:t.target.value}),className:v})]}),m!==null&&e.jsxs("div",{children:[e.jsx("div",{className:"h-2 overflow-hidden rounded-full bg-neutral-200 dark:bg-neutral-800",children:e.jsx("div",{className:"h-full rounded-full bg-brand-500 transition-[width]",style:{width:`${Math.round(m*100)}%`}})}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:m<1?`Wird hochgeladen … ${Math.round(m*100)} %`:"Wird gespeichert …"})]}),D&&e.jsx("p",{className:"text-sm text-red-600",children:D}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",disabled:h,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:s?"Speichern":"Hochladen"}),s&&e.jsx("button",{type:"button",onClick:w,disabled:h,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]}),e.jsx(q,{})]})]})}export{se as default}; +import{r as n,o as P,p as W,j as e,c as f,A as I}from"./index-Cc1wEeIX.js";import{b as V,A as M}from"./downloads-B9pqFegV.js";import{S as Z,s as T}from"./SortableList-DIXFCDYS.js";import{V as G}from"./ViewOnSite-CStAY6xT.js";import{E as H,a as J}from"./eye-BXFieSB3.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const v="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",j={title:"",description:"",sort_order:0};function A(d,o,i){return new Promise((c,u)=>{const a=new XMLHttpRequest;a.open("POST",`${I}${d}`),a.withCredentials=!0,a.upload.onprogress=s=>{s.lengthComputable&&i(s.loaded/s.total)},a.onload=()=>{let s=null;try{s=JSON.parse(a.responseText)}catch{}a.status>=200&&a.status<300?c(s):u(new Error((s==null?void 0:s.error)||(a.status===413?"Die Datei ist zu groß für diesen Server.":`Fehler ${a.status}`)))},a.onerror=()=>u(new Error("Netzwerkfehler beim Hochladen")),a.send(o)})}function q(){const[d,o]=n.useState(void 0),[i,c]=n.useState(""),[u,a]=n.useState(!1),[s,x]=n.useState(null);n.useEffect(()=>{f.get("/settings/downloads").then(l=>{o(l.password),c(l.password||"")}).catch(l=>x({kind:"error",text:l.message}))},[]);const m=async l=>{l.preventDefault(),a(!0),x(null);try{const h=await f.put("/settings/downloads",{password:i});o(h.password),c(h.password||""),x({kind:"ok",text:h.password?"Gespeichert – der Bereich ist jetzt geschützt.":"Gespeichert – der Bereich ist jetzt öffentlich."})}catch(h){x({kind:"error",text:h.message})}finally{a(!1)}};return e.jsxs("form",{onSubmit:m,className:"space-y-3 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:"Zugriffsschutz"}),e.jsxs("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:[d===void 0&&"Lädt…",d===null&&"Öffentlich – jeder, der die Seite aufruft, sieht die Dateien.",typeof d=="string"&&"Geschützt – Besucher müssen zuerst das Passwort eingeben."]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Zugangspasswort (leer = öffentlich)"}),e.jsx("input",{value:i,maxLength:100,autoComplete:"off",onChange:l=>c(l.target.value),className:v}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Das Passwort an die Kunden weitergeben – es bleibt hier jederzeit einsehbar. Direkte Links zu einzelnen Dateien funktionieren auch ohne Passwort; wer freigeschaltet hat, könnte sie also weitergeben."})]}),s&&e.jsx("p",{className:`text-sm ${s.kind==="error"?"text-red-600":"text-brand-600 dark:text-brand-400"}`,children:s.text}),e.jsx("button",{type:"submit",disabled:u||d===void 0,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:"Speichern"})]})}function se(){const[d,o]=n.useState([]),[i,c]=n.useState(j),[u,a]=n.useState(null),[s,x]=n.useState(null),[m,l]=n.useState(null),[h,S]=n.useState(!1),[D,g]=n.useState(""),[E,_]=n.useState(null),[C,z]=n.useState(j),k=n.useRef(null),$=n.useRef(null),b=P();W(!!u||JSON.stringify(i)!==JSON.stringify(C),"downloads");const y=()=>f.get("/downloads/manage").then(o);n.useEffect(()=>{y()},[]);const w=()=>{x(null),c(j),z(j),a(null),g(""),k.current&&(k.current.value="")},B=t=>{var p;w(),x(t.id);const r={title:t.title,description:t.description||"",sort_order:t.sort_order};c(r),z(r),(p=$.current)==null||p.scrollIntoView({behavior:"smooth",block:"start"})},F=async t=>{if(t.preventDefault(),!s&&!u){g("Bitte eine Datei auswählen.");return}S(!0),g("");try{if(s){if(await f.put(`/downloads/${s}`,i),u){const r=new FormData;r.append("file",u),l(0),await A(`/downloads/${s}/file`,r,l)}}else{const r=new FormData;r.append("file",u),r.append("title",i.title),r.append("description",i.description),l(0),await A("/downloads",r,l)}b.success(s?"Download gespeichert.":"Datei hochgeladen."),w(),y()}catch(r){g(r.message)}finally{S(!1),l(null)}},L=async t=>{_(t.id);try{const r=await f.patch(`/downloads/${t.id}/visibility`,{is_hidden:!t.is_hidden});o(p=>p.map(N=>N.id===t.id?{...N,is_hidden:r.is_hidden}:N)),b.success(r.is_hidden?`„${t.title}“ ist jetzt ausgeblendet.`:`„${t.title}“ ist wieder sichtbar.`)}catch(r){b.error(`Sichtbarkeit konnte nicht geändert werden: ${r.message}`)}finally{_(null)}},R=async t=>{if(confirm(`"${t.title}" inkl. Datei wirklich löschen?`))try{await f.delete(`/downloads/${t.id}`),s===t.id&&w(),b.success("Download gelöscht."),y()}catch(r){b.error(`Löschen fehlgeschlagen: ${r.message}`)}},O=async t=>{const r=d;o(t);try{o(await T("downloads",t)),b.success("Reihenfolge gespeichert.")}catch(p){o(r),b.error(`Reihenfolge konnte nicht gespeichert werden: ${p.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Downloads"}),e.jsx(G,{to:"/downloads"})]}),e.jsxs("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:["Dateien, die Kunden auf der Seite"," ",e.jsx("a",{href:"/downloads",target:"_blank",rel:"noopener noreferrer",className:"text-brand-600 hover:underline",children:"/downloads"})," ","anhören bzw. herunterladen können, z. B. Songs oder Anleitungen. Der Menüpunkt „Downloads“ erscheint auf der Website automatisch, sobald mindestens eine Datei sichtbar ist. Ohne Zugangspasswort (siehe „Zugriffsschutz“) ist die Seite öffentlich. Reihenfolge am Griff links per Ziehen ändern."]}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Titel / Datei"}),e.jsx("th",{className:"px-4 py-2",children:"Größe"}),e.jsx("th",{className:"px-4 py-2",children:"Website"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(Z,{items:d,onReorder:O,as:"tbody",className:"divide-y divide-neutral-100 bg-white dark:divide-neutral-800 dark:bg-neutral-950",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"px-2 py-2",children:r}),e.jsxs("td",{className:`px-4 py-2 ${t.is_hidden?"opacity-60":""}`,children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:t.title}),e.jsx("a",{href:t.file_path,target:"_blank",rel:"noopener noreferrer",className:"break-all text-xs text-neutral-500 hover:text-brand-600 dark:text-neutral-400",children:t.file_name})]}),e.jsx("td",{className:"whitespace-nowrap px-4 py-2 text-neutral-500 dark:text-neutral-400",children:V(t.file_size)}),e.jsx("td",{className:"px-4 py-2",children:e.jsxs("button",{type:"button",onClick:()=>L(t),disabled:E===t.id,title:t.is_hidden?"Wieder auf der Website anzeigen":"Auf der Website ausblenden",className:`inline-flex items-center gap-1.5 rounded-full border px-2.5 py-1 text-xs font-semibold transition disabled:opacity-50 ${t.is_hidden?"border-amber-300 bg-amber-50 text-amber-800 hover:bg-amber-100 dark:border-amber-700 dark:bg-amber-900/30 dark:text-amber-300":"border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:[t.is_hidden?e.jsx(H,{className:"h-3.5 w-3.5"}):e.jsx(J,{className:"h-3.5 w-3.5"}),t.is_hidden?"Ausgeblendet":"Sichtbar"]})}),e.jsxs("td",{className:"whitespace-nowrap px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>B(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>R(t),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),d.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:"Noch keine Dateien hochgeladen."})]})]}),e.jsxs("div",{className:"h-fit space-y-6",children:[e.jsxs("form",{ref:$,onSubmit:F,className:"scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:s?"Download bearbeiten":"Neue Datei hochladen"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:s?"Datei ersetzen (optional)":"Datei *"}),e.jsx("input",{ref:k,type:"file",accept:M.map(t=>`.${t}`).join(","),onChange:t=>{var r;return a(((r=t.target.files)==null?void 0:r[0])||null)},className:"block w-full text-sm text-neutral-600 file:mr-3 file:rounded-md file:border-0 file:bg-brand-500 file:px-3 file:py-2 file:text-sm file:font-semibold file:text-white hover:file:bg-brand-600 dark:text-neutral-300"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Musik (MP3, WAV, FLAC, …), Videos, PDFs, Bilder, Office-Dokumente oder ZIP-Archive. Andere Dateitypen bitte als ZIP hochladen."})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Titel ",s?"*":"(optional)"]}),e.jsx("input",{required:!!s,value:i.title,maxLength:150,onChange:t=>c({...i,title:t.target.value}),placeholder:s?"":"Leer lassen = Dateiname",className:v})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung (optional)"}),e.jsx("textarea",{rows:3,value:i.description,onChange:t=>c({...i,description:t.target.value}),className:v})]}),m!==null&&e.jsxs("div",{children:[e.jsx("div",{className:"h-2 overflow-hidden rounded-full bg-neutral-200 dark:bg-neutral-800",children:e.jsx("div",{className:"h-full rounded-full bg-brand-500 transition-[width]",style:{width:`${Math.round(m*100)}%`}})}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:m<1?`Wird hochgeladen … ${Math.round(m*100)} %`:"Wird gespeichert …"})]}),D&&e.jsx("p",{className:"text-sm text-red-600",children:D}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",disabled:h,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:s?"Speichern":"Hochladen"}),s&&e.jsx("button",{type:"button",onClick:w,disabled:h,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]}),e.jsx(q,{})]})]})}export{se as default}; diff --git a/hifi/assets/DownloadsPage-BIItFx8g.js b/hifi/assets/DownloadsPage-CMVi3G0A.js similarity index 97% rename from hifi/assets/DownloadsPage-BIItFx8g.js rename to hifi/assets/DownloadsPage-CMVi3G0A.js index 3f00f40..a62a656 100644 --- a/hifi/assets/DownloadsPage-BIItFx8g.js +++ b/hifi/assets/DownloadsPage-CMVi3G0A.js @@ -1 +1 @@ -import{r,u as y,b as v,j as e,e as S,R as D,c as I}from"./index-Tg8iNBwT.js";import{f as _,a as E,b as F,i as L}from"./downloads-B9pqFegV.js";import{L as C,F as p,a as R,b as T,c as U,M,D as A}from"./music-DPTNgOWL.js";const K={audio:M,video:U,pdf:p,image:T,archive:R,document:p},n="hifi-downloads-password",z=()=>{try{return localStorage.getItem(n)||""}catch{return""}},f=t=>{try{t?localStorage.setItem(n,t):localStorage.removeItem(n)}catch{}},g=t=>I.get("/downloads",t?{headers:{"X-Download-Password":encodeURIComponent(t)}}:void 0);function W(){const[t,i]=r.useState(null),[c,x]=r.useState(!1),[o,b]=r.useState(""),[j,m]=r.useState(!1),[u,h]=r.useState(!1),[d,w]=r.useState(null),{t:s,language:k}=y();r.useEffect(()=>{const a=z();g(a).then(l=>{l.locked?(a&&f(""),x(!0)):i(l.items)}).catch(l=>w(l))},[]);const N=async a=>{a.preventDefault(),h(!0),m(!1);try{const l=await g(o);l.locked?m(!0):(f(o),x(!1),i(l.items))}catch(l){w(l.message)}finally{h(!1)}};return v({title:s("downloadsPage.metaTitle"),description:s("downloadsPage.metaDescription"),path:"/downloads"}),e.jsxs("div",{className:"mx-auto max-w-4xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:s("downloadsPage.title")}),e.jsx("p",{className:"mb-10 max-w-2xl text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.intro")}),d&&e.jsx("p",{className:"text-red-600",children:typeof d=="string"?d:S(d,s)}),!d&&!c&&t===null&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.loading")}),(t==null?void 0:t.length)===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.empty")}),c&&e.jsxs("form",{onSubmit:N,className:"max-w-md rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[e.jsx(C,{className:"h-5 w-5 text-brand-500","aria-hidden":"true"}),e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:s("downloadsPage.lockedTitle")})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.lockedText")}),e.jsx("label",{htmlFor:"downloads-password",className:"sr-only",children:s("downloadsPage.passwordLabel")}),e.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row",children:[e.jsx("input",{id:"downloads-password",type:"password",required:!0,autoComplete:"off",value:o,onChange:a=>b(a.target.value),placeholder:s("downloadsPage.passwordLabel"),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm text-neutral-900 dark:border-neutral-700 dark:bg-neutral-950 dark:text-white"}),e.jsx("button",{type:"submit",disabled:u,className:"shrink-0 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:s(u?"downloadsPage.unlocking":"downloadsPage.unlock")})]}),j&&e.jsx("p",{className:"mt-2 text-sm text-red-600",role:"alert",children:s("downloadsPage.wrongPassword")})]}),e.jsx("div",{className:"space-y-4",children:t==null?void 0:t.map((a,l)=>{const P=K[_(a.file_name)];return e.jsx(D,{index:l%4,className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:e.jsxs("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-start",children:[e.jsx("div",{className:"flex h-12 w-12 shrink-0 items-center justify-center rounded-full bg-brand-500/10 text-brand-600 dark:text-brand-400",children:e.jsx(P,{className:"h-6 w-6","aria-hidden":"true"})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:a.title}),a.description&&e.jsx("p",{className:"mt-1 whitespace-pre-line text-sm text-neutral-600 dark:text-neutral-300",children:a.description}),e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:[E(a.file_name).toUpperCase()," · ",F(a.file_size,k==="de"?"de-DE":"en-US")]}),L(a.file_name)&&e.jsx("audio",{controls:!0,preload:"none",src:a.file_path,className:"mt-3 w-full"})]}),e.jsxs("a",{href:a.file_path,download:a.file_name,className:"inline-flex shrink-0 items-center justify-center gap-2 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:[e.jsx(A,{className:"h-4 w-4","aria-hidden":"true"}),s("downloadsPage.download")]})]})},a.id)})})]})}export{W as default}; +import{r,u as y,b as v,j as e,e as S,R as D,c as I}from"./index-Cc1wEeIX.js";import{f as _,a as E,b as F,i as L}from"./downloads-B9pqFegV.js";import{L as C,F as p,a as R,b as T,c as U,M,D as A}from"./music-B3GiJs_4.js";const K={audio:M,video:U,pdf:p,image:T,archive:R,document:p},n="hifi-downloads-password",z=()=>{try{return localStorage.getItem(n)||""}catch{return""}},f=t=>{try{t?localStorage.setItem(n,t):localStorage.removeItem(n)}catch{}},g=t=>I.get("/downloads",t?{headers:{"X-Download-Password":encodeURIComponent(t)}}:void 0);function W(){const[t,i]=r.useState(null),[c,x]=r.useState(!1),[o,b]=r.useState(""),[j,m]=r.useState(!1),[u,h]=r.useState(!1),[d,w]=r.useState(null),{t:s,language:k}=y();r.useEffect(()=>{const a=z();g(a).then(l=>{l.locked?(a&&f(""),x(!0)):i(l.items)}).catch(l=>w(l))},[]);const N=async a=>{a.preventDefault(),h(!0),m(!1);try{const l=await g(o);l.locked?m(!0):(f(o),x(!1),i(l.items))}catch(l){w(l.message)}finally{h(!1)}};return v({title:s("downloadsPage.metaTitle"),description:s("downloadsPage.metaDescription"),path:"/downloads"}),e.jsxs("div",{className:"mx-auto max-w-4xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:s("downloadsPage.title")}),e.jsx("p",{className:"mb-10 max-w-2xl text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.intro")}),d&&e.jsx("p",{className:"text-red-600",children:typeof d=="string"?d:S(d,s)}),!d&&!c&&t===null&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.loading")}),(t==null?void 0:t.length)===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:s("downloadsPage.empty")}),c&&e.jsxs("form",{onSubmit:N,className:"max-w-md rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[e.jsx(C,{className:"h-5 w-5 text-brand-500","aria-hidden":"true"}),e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:s("downloadsPage.lockedTitle")})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:s("downloadsPage.lockedText")}),e.jsx("label",{htmlFor:"downloads-password",className:"sr-only",children:s("downloadsPage.passwordLabel")}),e.jsxs("div",{className:"flex flex-col gap-2 sm:flex-row",children:[e.jsx("input",{id:"downloads-password",type:"password",required:!0,autoComplete:"off",value:o,onChange:a=>b(a.target.value),placeholder:s("downloadsPage.passwordLabel"),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm text-neutral-900 dark:border-neutral-700 dark:bg-neutral-950 dark:text-white"}),e.jsx("button",{type:"submit",disabled:u,className:"shrink-0 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:s(u?"downloadsPage.unlocking":"downloadsPage.unlock")})]}),j&&e.jsx("p",{className:"mt-2 text-sm text-red-600",role:"alert",children:s("downloadsPage.wrongPassword")})]}),e.jsx("div",{className:"space-y-4",children:t==null?void 0:t.map((a,l)=>{const P=K[_(a.file_name)];return e.jsx(D,{index:l%4,className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:e.jsxs("div",{className:"flex flex-col gap-4 sm:flex-row sm:items-start",children:[e.jsx("div",{className:"flex h-12 w-12 shrink-0 items-center justify-center rounded-full bg-brand-500/10 text-brand-600 dark:text-brand-400",children:e.jsx(P,{className:"h-6 w-6","aria-hidden":"true"})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:a.title}),a.description&&e.jsx("p",{className:"mt-1 whitespace-pre-line text-sm text-neutral-600 dark:text-neutral-300",children:a.description}),e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:[E(a.file_name).toUpperCase()," · ",F(a.file_size,k==="de"?"de-DE":"en-US")]}),L(a.file_name)&&e.jsx("audio",{controls:!0,preload:"none",src:a.file_path,className:"mt-3 w-full"})]}),e.jsxs("a",{href:a.file_path,download:a.file_name,className:"inline-flex shrink-0 items-center justify-center gap-2 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:[e.jsx(A,{className:"h-4 w-4","aria-hidden":"true"}),s("downloadsPage.download")]})]})},a.id)})})]})}export{W as default}; diff --git a/hifi/assets/EmailSettings-CnX83jWY.js b/hifi/assets/EmailSettings-Bbg5xyAa.js similarity index 98% rename from hifi/assets/EmailSettings-CnX83jWY.js rename to hifi/assets/EmailSettings-Bbg5xyAa.js index a1e7a28..fd3f7c7 100644 --- a/hifi/assets/EmailSettings-CnX83jWY.js +++ b/hifi/assets/EmailSettings-Bbg5xyAa.js @@ -1,2 +1,2 @@ -import{r,c as m,j as e}from"./index-Tg8iNBwT.js";import{R as E}from"./RichTextEditor-kI3KpNag.js";function d(a){if(!a)return"";if(/<[a-z][\s\S]*>/i.test(a))return a;const l=document.createElement("div");return l.textContent=a,`

${l.innerHTML.replace(/\n/g,"
")}

`}const H={mail_host:"",mail_port:587,mail_username:"",mail_password:"",mail_encryption:"tls",mail_from_email:"",mail_from_name:"",mail_notify_email:"",mail_customer_subject:"",mail_customer_body:"",mail_owner_subject:"",mail_owner_body:""},z=[["{{name}}","Name des Kunden"],["{{email}}","E-Mail des Kunden"],["{{phone}}","Telefonnummer"],["{{vin}}","Fahrgestellnummer (FIN)"],["{{message}}","Nachricht des Kunden"],["{{brand}}","Marke"],["{{model}}","Modell"],["{{package}}","Paket"],["{{product}}","Produkt"],["{{upgrades}}","Gewählte Upgrades"]];function T(){return e.jsx("div",{className:"mt-3 flex flex-wrap gap-1.5",children:z.map(([a,l])=>e.jsx("span",{title:l,className:"rounded-md bg-neutral-100 px-2 py-1 font-mono text-xs text-neutral-600 dark:bg-neutral-800 dark:text-neutral-300",children:a},a))})}function D(){const[a,l]=r.useState(H),[u,c]=r.useState(!1),[C,P]=r.useState(!0),[x,M]=r.useState(!1),[b,h]=r.useState(!1),[p,g]=r.useState(""),[B,o]=r.useState(!1),[f,k]=r.useState(!1),[_,j]=r.useState(""),[w,v]=r.useState(""),[y,N]=r.useState(""),[i,S]=r.useState(null);r.useEffect(()=>{m.get("/settings/mail").then(t=>{l({...t,mail_password:"",mail_customer_body:d(t.mail_customer_body),mail_owner_body:d(t.mail_owner_body)}),c(t.has_password)}).finally(()=>P(!1))},[]);const s=(t,n)=>{l(A=>({...A,[t]:n})),o(!1)},K=async t=>{t.preventDefault(),h(!0),g(""),o(!1);try{const n=await m.post("/settings/mail",a);l({...n,mail_password:"",mail_customer_body:d(n.mail_customer_body),mail_owner_body:d(n.mail_owner_body)}),c(n.has_password),o(!0)}catch(n){g(n.message)}finally{h(!1)}},L=async()=>{k(!0),j(""),v(""),N(""),S(null);try{const t=await m.post("/settings/mail/test",a);v(`Testmail gesendet an ${t.sent_to}. Der Server hat die Mail angenommen - prüfe auch den Spam-Ordner, das ist noch keine Garantie für die Zustellung.`),N(t.warning||""),S(t.smtp_log||null)}catch(t){j(t.message)}finally{k(!1)}};return C?e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsxs("form",{onSubmit:K,className:"max-w-2xl space-y-6",children:[e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"SMTP-Server"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Zugangsdaten deines Mail-Postfachs oder Transactional-Mail-Anbieters. Solange kein Server eingetragen ist, werden keine E-Mails verschickt (Kontaktanfragen werden trotzdem in der Datenbank gespeichert)."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-[1fr_120px]",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Server (Host)"}),e.jsx("input",{value:a.mail_host,onChange:t=>s("mail_host",t.target.value),placeholder:"smtp.beispiel.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Port"}),e.jsx("input",{type:"number",value:a.mail_port,onChange:t=>s("mail_port",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Verschlüsselung"}),e.jsxs("select",{value:a.mail_encryption,onChange:t=>s("mail_encryption",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"tls",children:"STARTTLS"}),e.jsx("option",{value:"ssl",children:"SSL"}),e.jsx("option",{value:"none",children:"Keine"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername"}),e.jsx("input",{value:a.mail_username,onChange:t=>s("mail_username",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Passwort ",u?"(leer lassen = unverändert)":""]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("input",{type:x?"text":"password",value:a.mail_password,onChange:t=>s("mail_password",t.target.value),placeholder:u?"••••••••":"",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("button",{type:"button",onClick:()=>M(t=>!t),className:"shrink-0 rounded-md border border-neutral-300 px-3 text-sm dark:border-neutral-700",children:x?"Verbergen":"Anzeigen"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Absender-E-Mail"}),e.jsx("input",{type:"email",value:a.mail_from_email,onChange:t=>s("mail_from_email",t.target.value),placeholder:"info@hifi-planet-amorbach.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Absender-Name"}),e.jsx("input",{value:a.mail_from_name,onChange:t=>s("mail_from_name",t.target.value),placeholder:"HifiPlanet",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]}),e.jsxs("div",{className:"mt-4 border-t border-neutral-200 pt-4 dark:border-neutral-800",children:[_&&e.jsx("p",{className:"mb-2 whitespace-pre-wrap text-sm text-red-600",children:_}),w&&e.jsx("p",{className:"mb-2 text-sm text-green-600 dark:text-green-400",children:w}),y&&e.jsx("p",{className:"mb-2 rounded-md bg-amber-50 p-2 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:y}),e.jsx("button",{type:"button",onClick:L,disabled:f,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm font-medium hover:bg-neutral-50 disabled:opacity-50 dark:border-neutral-700 dark:hover:bg-neutral-800",children:f?"Sende Testmail…":"Verbindung testen"}),i&&i.length>0&&e.jsxs("details",{className:"mt-3",children:[e.jsx("summary",{className:"cursor-pointer text-xs text-neutral-500 dark:text-neutral-400",children:"SMTP-Protokoll anzeigen"}),e.jsx("pre",{className:"mt-2 max-h-64 overflow-auto rounded-md bg-neutral-900 p-3 text-xs text-neutral-200",children:i.join(` +import{r,c as m,j as e}from"./index-Cc1wEeIX.js";import{R as E}from"./RichTextEditor-BGWsKoCk.js";function d(a){if(!a)return"";if(/<[a-z][\s\S]*>/i.test(a))return a;const l=document.createElement("div");return l.textContent=a,`

${l.innerHTML.replace(/\n/g,"
")}

`}const H={mail_host:"",mail_port:587,mail_username:"",mail_password:"",mail_encryption:"tls",mail_from_email:"",mail_from_name:"",mail_notify_email:"",mail_customer_subject:"",mail_customer_body:"",mail_owner_subject:"",mail_owner_body:""},z=[["{{name}}","Name des Kunden"],["{{email}}","E-Mail des Kunden"],["{{phone}}","Telefonnummer"],["{{vin}}","Fahrgestellnummer (FIN)"],["{{message}}","Nachricht des Kunden"],["{{brand}}","Marke"],["{{model}}","Modell"],["{{package}}","Paket"],["{{product}}","Produkt"],["{{upgrades}}","Gewählte Upgrades"]];function T(){return e.jsx("div",{className:"mt-3 flex flex-wrap gap-1.5",children:z.map(([a,l])=>e.jsx("span",{title:l,className:"rounded-md bg-neutral-100 px-2 py-1 font-mono text-xs text-neutral-600 dark:bg-neutral-800 dark:text-neutral-300",children:a},a))})}function D(){const[a,l]=r.useState(H),[u,c]=r.useState(!1),[C,P]=r.useState(!0),[x,M]=r.useState(!1),[b,h]=r.useState(!1),[p,g]=r.useState(""),[B,o]=r.useState(!1),[f,k]=r.useState(!1),[_,j]=r.useState(""),[w,v]=r.useState(""),[y,N]=r.useState(""),[i,S]=r.useState(null);r.useEffect(()=>{m.get("/settings/mail").then(t=>{l({...t,mail_password:"",mail_customer_body:d(t.mail_customer_body),mail_owner_body:d(t.mail_owner_body)}),c(t.has_password)}).finally(()=>P(!1))},[]);const s=(t,n)=>{l(A=>({...A,[t]:n})),o(!1)},K=async t=>{t.preventDefault(),h(!0),g(""),o(!1);try{const n=await m.post("/settings/mail",a);l({...n,mail_password:"",mail_customer_body:d(n.mail_customer_body),mail_owner_body:d(n.mail_owner_body)}),c(n.has_password),o(!0)}catch(n){g(n.message)}finally{h(!1)}},L=async()=>{k(!0),j(""),v(""),N(""),S(null);try{const t=await m.post("/settings/mail/test",a);v(`Testmail gesendet an ${t.sent_to}. Der Server hat die Mail angenommen - prüfe auch den Spam-Ordner, das ist noch keine Garantie für die Zustellung.`),N(t.warning||""),S(t.smtp_log||null)}catch(t){j(t.message)}finally{k(!1)}};return C?e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsxs("form",{onSubmit:K,className:"max-w-2xl space-y-6",children:[e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"SMTP-Server"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Zugangsdaten deines Mail-Postfachs oder Transactional-Mail-Anbieters. Solange kein Server eingetragen ist, werden keine E-Mails verschickt (Kontaktanfragen werden trotzdem in der Datenbank gespeichert)."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-[1fr_120px]",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Server (Host)"}),e.jsx("input",{value:a.mail_host,onChange:t=>s("mail_host",t.target.value),placeholder:"smtp.beispiel.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Port"}),e.jsx("input",{type:"number",value:a.mail_port,onChange:t=>s("mail_port",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Verschlüsselung"}),e.jsxs("select",{value:a.mail_encryption,onChange:t=>s("mail_encryption",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"tls",children:"STARTTLS"}),e.jsx("option",{value:"ssl",children:"SSL"}),e.jsx("option",{value:"none",children:"Keine"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername"}),e.jsx("input",{value:a.mail_username,onChange:t=>s("mail_username",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Passwort ",u?"(leer lassen = unverändert)":""]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("input",{type:x?"text":"password",value:a.mail_password,onChange:t=>s("mail_password",t.target.value),placeholder:u?"••••••••":"",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("button",{type:"button",onClick:()=>M(t=>!t),className:"shrink-0 rounded-md border border-neutral-300 px-3 text-sm dark:border-neutral-700",children:x?"Verbergen":"Anzeigen"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Absender-E-Mail"}),e.jsx("input",{type:"email",value:a.mail_from_email,onChange:t=>s("mail_from_email",t.target.value),placeholder:"info@hifi-planet-amorbach.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Absender-Name"}),e.jsx("input",{value:a.mail_from_name,onChange:t=>s("mail_from_name",t.target.value),placeholder:"HifiPlanet",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]}),e.jsxs("div",{className:"mt-4 border-t border-neutral-200 pt-4 dark:border-neutral-800",children:[_&&e.jsx("p",{className:"mb-2 whitespace-pre-wrap text-sm text-red-600",children:_}),w&&e.jsx("p",{className:"mb-2 text-sm text-green-600 dark:text-green-400",children:w}),y&&e.jsx("p",{className:"mb-2 rounded-md bg-amber-50 p-2 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:y}),e.jsx("button",{type:"button",onClick:L,disabled:f,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm font-medium hover:bg-neutral-50 disabled:opacity-50 dark:border-neutral-700 dark:hover:bg-neutral-800",children:f?"Sende Testmail…":"Verbindung testen"}),i&&i.length>0&&e.jsxs("details",{className:"mt-3",children:[e.jsx("summary",{className:"cursor-pointer text-xs text-neutral-500 dark:text-neutral-400",children:"SMTP-Protokoll anzeigen"}),e.jsx("pre",{className:"mt-2 max-h-64 overflow-auto rounded-md bg-neutral-900 p-3 text-xs text-neutral-200",children:i.join(` `)})]})]})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Empfänger"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"An diese Adresse geht die Benachrichtigung bei jeder neuen Kontaktanfrage."}),e.jsx("input",{type:"email",value:a.mail_notify_email,onChange:t=>s("mail_notify_email",t.target.value),placeholder:"info@hifi-planet-amorbach.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"E-Mail an den Kunden (Bestätigung)"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Geht automatisch an den Kunden, sobald er eine Kontaktanfrage abschickt."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Betreff"}),e.jsx("input",{value:a.mail_customer_subject,onChange:t=>s("mail_customer_subject",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(E,{label:"Text",value:a.mail_customer_body,onChange:t=>s("mail_customer_body",t)})]}),e.jsx(T,{})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"E-Mail an den Shop (Benachrichtigung)"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Geht an die oben eingestellte Empfänger-Adresse, sobald eine neue Kontaktanfrage eingeht."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Betreff"}),e.jsx("input",{value:a.mail_owner_subject,onChange:t=>s("mail_owner_subject",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(E,{label:"Text",value:a.mail_owner_body,onChange:t=>s("mail_owner_body",t)})]}),e.jsx(T,{})]}),p&&e.jsx("p",{className:"text-sm text-red-600",children:p}),B&&e.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),e.jsx("button",{type:"submit",disabled:b,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:b?"Speichere…":"Speichern"})]})}export{D as default}; diff --git a/hifi/assets/ExportImportSettings-Dz31tCNC.js b/hifi/assets/ExportImportSettings-uCQ9DCjI.js similarity index 99% rename from hifi/assets/ExportImportSettings-Dz31tCNC.js rename to hifi/assets/ExportImportSettings-uCQ9DCjI.js index 7b08d14..6b5e1e4 100644 --- a/hifi/assets/ExportImportSettings-Dz31tCNC.js +++ b/hifi/assets/ExportImportSettings-uCQ9DCjI.js @@ -1 +1 @@ -import{r as n,j as e,A as D,c as F}from"./index-Tg8iNBwT.js";const p=[{key:"catalog",label:"Fahrzeug-Katalog",hint:"Marken, Modelle (inkl. Bilder), Pakete, Produkte, Upgrades",tables:["brands","car_models","packages","package_products","package_upgrades"]},{key:"services",label:"Leistungen",hint:"Die Leistungen-Übersicht",tables:["services"]},{key:"faqs",label:"FAQs",hint:"Häufig gestellte Fragen",tables:["faqs"]},{key:"gallery",label:"Bildergalerie",hint:"Galerie-Marken, Projekte und Fotos (inkl. Bilder)",tables:["gallery_brands","gallery_projects","gallery_photos"]},{key:"settings",label:"Einstellungen",hint:"Telefon/Adresse/Öffnungszeiten, Logo, Wartungsmodus-Texte, Kachel-Design, Mail-Vorlagen (ohne Zugangsdaten)",tables:["app_settings"]},{key:"legal",label:"Rechtstexte",hint:"Impressum, Datenschutzerklärung, AGB",tables:["legal_pages"]},{key:"home",label:"Startseiten-Texte",hint:'Hero, YouTube-Sektion, Handwerk, Beratung, Einblicke, "Mehr als Car-Hifi"',tables:["home_sections"]},{key:"partners",label:"Partner",hint:"Marken-Logozeile auf der Startseite (inkl. Logos)",tables:["partners"]},{key:"translations",label:"Englische Texte",hint:"Englische Fassungen von Leistungen, Paketen und Upgrades",tables:["content_translations"]},{key:"permissions",label:"Berechtigungsgruppen",hint:"Rollen-Vorlagen und ihre Rechte (ohne Benutzerkonten selbst)",tables:["permission_groups","permission_group_permissions"]}],z={brands:"Marken",car_models:"Modelle",packages:"Pakete",package_products:"Produkte",package_upgrades:"Upgrades",services:"Leistungen",faqs:"FAQs",gallery_brands:"Galerie-Marken",gallery_projects:"Galerie-Projekte",gallery_photos:"Galerie-Fotos",app_settings:"Einstellungen",legal_pages:"Rechtstexte",home_sections:"Startseiten-Texte",partners:"Partner",content_translations:"Englische Texte",permission_groups:"Berechtigungsgruppen",permission_group_permissions:"Berechtigungsgruppen-Rechte",admin_users:"Benutzerkonten",admin_user_permissions:"Benutzer-Einzelrechte",admin_user_groups:"Benutzer-Gruppenzuweisungen"},L=(l,d)=>{if(!l)return null;const i=d.map(s=>[s,Array.isArray(l[s])?l[s].length:0]).filter(([,s])=>s>0).map(([s,c])=>`${c} ${z[s]||s}`);return i.length?i.join(", "):"leer in dieser Datei"};function C(){const[l,d]=n.useState(null),[i,s]=n.useState(null),[c,y]=n.useState(""),[o,w]=n.useState(()=>new Set(p.map(t=>t.key))),[N,E]=n.useState(!1),[g,m]=n.useState(!1),[h,_]=n.useState(!1),[S,B]=n.useState(!1),[u,x]=n.useState(null),[v,b]=n.useState(""),A=async t=>{var a;const r=((a=t.target.files)==null?void 0:a[0])||null;if(d(r),x(null),b(""),s(null),y(""),w(new Set(p.map(f=>f.key))),m(!1),!!r)try{const f=await r.text(),j=JSON.parse(f);if(!j||typeof j.data!="object")throw new Error("kein gültiges Export-Format");s(j.data)}catch{y("Datei konnte nicht gelesen werden – Vorschau der Inhalte nicht möglich. Import würde trotzdem versucht (alle Bereiche).")}},I=t=>{w(r=>{const a=new Set(r);return a.has(t)?a.delete(t):a.add(t),a})},P=async t=>{if(t.preventDefault(),!(!l||!h||o.size===0)){B(!0),b(""),x(null);try{const r=new FormData;r.append("file",l),r.append("sections",JSON.stringify([...o])),r.append("include_accounts",g?"1":"0");const a=await F.post("/settings/import",r);x(a),d(null),s(null),_(!1),m(!1),t.target.reset()}catch(r){b(r.message)}finally{B(!1)}}},k=p.filter(t=>o.has(t.key)).map(t=>t.label);return g&&k.push("Benutzerkonten"),e.jsxs("div",{className:"max-w-2xl space-y-6",children:[e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Daten exportieren"}),e.jsxs("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:["Lädt eine Datei mit allen Marken, Modellen, Paketen, Produkten, Upgrades, Leistungen, FAQs, der kompletten Bildergalerie (inkl. Bilder), den Einstellungen und den Berechtigungsgruppen herunter (ohne Zugangsdaten wie SMTP-Passwort oder API-Keys – die müssen auf jedem Server neu eingetragen werden). Kontaktanfragen sind bewusst ",e.jsx("strong",{children:"nicht"})," enthalten."]}),e.jsxs("label",{className:"mb-3 flex items-start gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:N,onChange:t=>E(t.target.checked),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"Benutzerkonten mit exportieren (enthält Passwort-Hashes und 2FA-Geheimnisse – nur für Backups an einem vertrauenswürdigen Ort)"]}),e.jsx("a",{href:`${D}/settings/export${N?"?include_accounts=1":""}`,className:"inline-block rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:"Jetzt exportieren"})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Daten importieren"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Lädt eine zuvor exportierte Datei auf diesen Server. Ersetzt dabei die ausgewählten Bereiche komplett durch den Inhalt der Datei – das kann nicht rückgängig gemacht werden. Kontaktanfragen bleiben immer unangetastet, Benutzerkonten nur wenn unten explizit angehakt."}),e.jsxs("form",{onSubmit:P,className:"space-y-4",children:[e.jsx("input",{type:"file",accept:"application/json,.json",onChange:A,className:"text-sm"}),l&&e.jsxs("div",{className:"rounded-lg border border-neutral-200 dark:border-neutral-700",children:[e.jsx("div",{className:"border-b border-neutral-200 px-4 py-2 text-xs font-semibold uppercase tracking-wide text-neutral-500 dark:border-neutral-700 dark:text-neutral-400",children:"Was soll importiert werden?"}),c&&e.jsx("p",{className:"px-4 pt-3 text-sm text-amber-600 dark:text-amber-400",children:c}),e.jsxs("div",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[p.map(t=>e.jsxs("label",{className:"flex cursor-pointer items-start gap-3 px-4 py-3 hover:bg-neutral-50 dark:hover:bg-neutral-800/50",children:[e.jsx("input",{type:"checkbox",checked:o.has(t.key),onChange:()=>I(t.key),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),e.jsxs("span",{className:"flex-1",children:[e.jsx("span",{className:"block text-sm font-medium text-neutral-800 dark:text-neutral-100",children:t.label}),e.jsx("span",{className:"block text-xs text-neutral-500 dark:text-neutral-400",children:i?L(i,t.tables):t.hint})]})]},t.key)),e.jsxs("label",{className:"flex cursor-pointer items-start gap-3 px-4 py-3 hover:bg-neutral-50 dark:hover:bg-neutral-800/50",children:[e.jsx("input",{type:"checkbox",checked:g,onChange:t=>m(t.target.checked),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),e.jsxs("span",{className:"flex-1",children:[e.jsx("span",{className:"block text-sm font-medium text-neutral-800 dark:text-neutral-100",children:"Benutzerkonten"}),e.jsx("span",{className:"block text-xs text-neutral-500 dark:text-neutral-400",children:'Nur wenn die Datei mit "Benutzerkonten mit exportieren" erstellt wurde. Ersetzt auch dein eigenes Konto – danach ggf. mit den Zugangsdaten aus der Export-Datei neu einloggen.'})]})]})]})]}),e.jsxs("label",{className:"flex items-start gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:h,onChange:t=>_(t.target.checked),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"Mir ist bewusst, dass dies"," ",k.length?e.jsx("strong",{children:k.join(", ")}):"die ausgewählten Bereiche"," auf diesem Server unwiderruflich ersetzt."]}),e.jsx("button",{type:"submit",disabled:!l||!h||S||o.size===0,className:"rounded-md bg-red-600 px-4 py-2 text-sm font-semibold text-white hover:bg-red-700 disabled:opacity-50",children:S?"Importiere…":"Importieren"})]}),v&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:v}),u&&e.jsxs("div",{className:"mt-3 rounded-md bg-green-50 p-3 text-sm text-green-800 dark:bg-green-900/20 dark:text-green-300",children:[e.jsx("p",{className:"mb-1 font-semibold",children:"Import erfolgreich:"}),e.jsxs("ul",{className:"list-disc pl-5",children:[Object.entries(u.counts).map(([t,r])=>e.jsxs("li",{children:[r," ",z[t]||t]},t)),u.images_restored>0&&e.jsxs("li",{children:[u.images_restored," Bilder wiederhergestellt"]})]})]})]})]})}export{C as default}; +import{r as n,j as e,A as D,c as F}from"./index-Cc1wEeIX.js";const p=[{key:"catalog",label:"Fahrzeug-Katalog",hint:"Marken, Modelle (inkl. Bilder), Pakete, Produkte, Upgrades",tables:["brands","car_models","packages","package_products","package_upgrades"]},{key:"services",label:"Leistungen",hint:"Die Leistungen-Übersicht",tables:["services"]},{key:"faqs",label:"FAQs",hint:"Häufig gestellte Fragen",tables:["faqs"]},{key:"gallery",label:"Bildergalerie",hint:"Galerie-Marken, Projekte und Fotos (inkl. Bilder)",tables:["gallery_brands","gallery_projects","gallery_photos"]},{key:"settings",label:"Einstellungen",hint:"Telefon/Adresse/Öffnungszeiten, Logo, Wartungsmodus-Texte, Kachel-Design, Mail-Vorlagen (ohne Zugangsdaten)",tables:["app_settings"]},{key:"legal",label:"Rechtstexte",hint:"Impressum, Datenschutzerklärung, AGB",tables:["legal_pages"]},{key:"home",label:"Startseiten-Texte",hint:'Hero, YouTube-Sektion, Handwerk, Beratung, Einblicke, "Mehr als Car-Hifi"',tables:["home_sections"]},{key:"partners",label:"Partner",hint:"Marken-Logozeile auf der Startseite (inkl. Logos)",tables:["partners"]},{key:"translations",label:"Englische Texte",hint:"Englische Fassungen von Leistungen, Paketen und Upgrades",tables:["content_translations"]},{key:"permissions",label:"Berechtigungsgruppen",hint:"Rollen-Vorlagen und ihre Rechte (ohne Benutzerkonten selbst)",tables:["permission_groups","permission_group_permissions"]}],z={brands:"Marken",car_models:"Modelle",packages:"Pakete",package_products:"Produkte",package_upgrades:"Upgrades",services:"Leistungen",faqs:"FAQs",gallery_brands:"Galerie-Marken",gallery_projects:"Galerie-Projekte",gallery_photos:"Galerie-Fotos",app_settings:"Einstellungen",legal_pages:"Rechtstexte",home_sections:"Startseiten-Texte",partners:"Partner",content_translations:"Englische Texte",permission_groups:"Berechtigungsgruppen",permission_group_permissions:"Berechtigungsgruppen-Rechte",admin_users:"Benutzerkonten",admin_user_permissions:"Benutzer-Einzelrechte",admin_user_groups:"Benutzer-Gruppenzuweisungen"},L=(l,d)=>{if(!l)return null;const i=d.map(s=>[s,Array.isArray(l[s])?l[s].length:0]).filter(([,s])=>s>0).map(([s,c])=>`${c} ${z[s]||s}`);return i.length?i.join(", "):"leer in dieser Datei"};function C(){const[l,d]=n.useState(null),[i,s]=n.useState(null),[c,y]=n.useState(""),[o,w]=n.useState(()=>new Set(p.map(t=>t.key))),[N,E]=n.useState(!1),[g,m]=n.useState(!1),[h,_]=n.useState(!1),[S,B]=n.useState(!1),[u,x]=n.useState(null),[v,b]=n.useState(""),A=async t=>{var a;const r=((a=t.target.files)==null?void 0:a[0])||null;if(d(r),x(null),b(""),s(null),y(""),w(new Set(p.map(f=>f.key))),m(!1),!!r)try{const f=await r.text(),j=JSON.parse(f);if(!j||typeof j.data!="object")throw new Error("kein gültiges Export-Format");s(j.data)}catch{y("Datei konnte nicht gelesen werden – Vorschau der Inhalte nicht möglich. Import würde trotzdem versucht (alle Bereiche).")}},I=t=>{w(r=>{const a=new Set(r);return a.has(t)?a.delete(t):a.add(t),a})},P=async t=>{if(t.preventDefault(),!(!l||!h||o.size===0)){B(!0),b(""),x(null);try{const r=new FormData;r.append("file",l),r.append("sections",JSON.stringify([...o])),r.append("include_accounts",g?"1":"0");const a=await F.post("/settings/import",r);x(a),d(null),s(null),_(!1),m(!1),t.target.reset()}catch(r){b(r.message)}finally{B(!1)}}},k=p.filter(t=>o.has(t.key)).map(t=>t.label);return g&&k.push("Benutzerkonten"),e.jsxs("div",{className:"max-w-2xl space-y-6",children:[e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Daten exportieren"}),e.jsxs("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:["Lädt eine Datei mit allen Marken, Modellen, Paketen, Produkten, Upgrades, Leistungen, FAQs, der kompletten Bildergalerie (inkl. Bilder), den Einstellungen und den Berechtigungsgruppen herunter (ohne Zugangsdaten wie SMTP-Passwort oder API-Keys – die müssen auf jedem Server neu eingetragen werden). Kontaktanfragen sind bewusst ",e.jsx("strong",{children:"nicht"})," enthalten."]}),e.jsxs("label",{className:"mb-3 flex items-start gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:N,onChange:t=>E(t.target.checked),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"Benutzerkonten mit exportieren (enthält Passwort-Hashes und 2FA-Geheimnisse – nur für Backups an einem vertrauenswürdigen Ort)"]}),e.jsx("a",{href:`${D}/settings/export${N?"?include_accounts=1":""}`,className:"inline-block rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:"Jetzt exportieren"})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Daten importieren"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Lädt eine zuvor exportierte Datei auf diesen Server. Ersetzt dabei die ausgewählten Bereiche komplett durch den Inhalt der Datei – das kann nicht rückgängig gemacht werden. Kontaktanfragen bleiben immer unangetastet, Benutzerkonten nur wenn unten explizit angehakt."}),e.jsxs("form",{onSubmit:P,className:"space-y-4",children:[e.jsx("input",{type:"file",accept:"application/json,.json",onChange:A,className:"text-sm"}),l&&e.jsxs("div",{className:"rounded-lg border border-neutral-200 dark:border-neutral-700",children:[e.jsx("div",{className:"border-b border-neutral-200 px-4 py-2 text-xs font-semibold uppercase tracking-wide text-neutral-500 dark:border-neutral-700 dark:text-neutral-400",children:"Was soll importiert werden?"}),c&&e.jsx("p",{className:"px-4 pt-3 text-sm text-amber-600 dark:text-amber-400",children:c}),e.jsxs("div",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[p.map(t=>e.jsxs("label",{className:"flex cursor-pointer items-start gap-3 px-4 py-3 hover:bg-neutral-50 dark:hover:bg-neutral-800/50",children:[e.jsx("input",{type:"checkbox",checked:o.has(t.key),onChange:()=>I(t.key),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),e.jsxs("span",{className:"flex-1",children:[e.jsx("span",{className:"block text-sm font-medium text-neutral-800 dark:text-neutral-100",children:t.label}),e.jsx("span",{className:"block text-xs text-neutral-500 dark:text-neutral-400",children:i?L(i,t.tables):t.hint})]})]},t.key)),e.jsxs("label",{className:"flex cursor-pointer items-start gap-3 px-4 py-3 hover:bg-neutral-50 dark:hover:bg-neutral-800/50",children:[e.jsx("input",{type:"checkbox",checked:g,onChange:t=>m(t.target.checked),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),e.jsxs("span",{className:"flex-1",children:[e.jsx("span",{className:"block text-sm font-medium text-neutral-800 dark:text-neutral-100",children:"Benutzerkonten"}),e.jsx("span",{className:"block text-xs text-neutral-500 dark:text-neutral-400",children:'Nur wenn die Datei mit "Benutzerkonten mit exportieren" erstellt wurde. Ersetzt auch dein eigenes Konto – danach ggf. mit den Zugangsdaten aus der Export-Datei neu einloggen.'})]})]})]})]}),e.jsxs("label",{className:"flex items-start gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:h,onChange:t=>_(t.target.checked),className:"mt-0.5 h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"Mir ist bewusst, dass dies"," ",k.length?e.jsx("strong",{children:k.join(", ")}):"die ausgewählten Bereiche"," auf diesem Server unwiderruflich ersetzt."]}),e.jsx("button",{type:"submit",disabled:!l||!h||S||o.size===0,className:"rounded-md bg-red-600 px-4 py-2 text-sm font-semibold text-white hover:bg-red-700 disabled:opacity-50",children:S?"Importiere…":"Importieren"})]}),v&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:v}),u&&e.jsxs("div",{className:"mt-3 rounded-md bg-green-50 p-3 text-sm text-green-800 dark:bg-green-900/20 dark:text-green-300",children:[e.jsx("p",{className:"mb-1 font-semibold",children:"Import erfolgreich:"}),e.jsxs("ul",{className:"list-disc pl-5",children:[Object.entries(u.counts).map(([t,r])=>e.jsxs("li",{children:[r," ",z[t]||t]},t)),u.images_restored>0&&e.jsxs("li",{children:[u.images_restored," Bilder wiederhergestellt"]})]})]})]})]})}export{C as default}; diff --git a/hifi/assets/Faqs-DN4tIka3.js b/hifi/assets/Faqs-Mcg7d29g.js similarity index 95% rename from hifi/assets/Faqs-DN4tIka3.js rename to hifi/assets/Faqs-Mcg7d29g.js index 6cbbbc3..c0e3c0c 100644 --- a/hifi/assets/Faqs-DN4tIka3.js +++ b/hifi/assets/Faqs-Mcg7d29g.js @@ -1 +1 @@ -import{o as F,r as l,p as S,j as e,c as m}from"./index-Tg8iNBwT.js";import{S as E,s as R}from"./SortableList-DRJ1jYgo.js";import{V as A}from"./ViewOnSite-CVVA03Ho.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const h={question_de:"",answer_de:"",question_en:"",answer_en:"",sort_order:0};function O(){const i=F(),[o,c]=l.useState([]),[r,d]=l.useState(h),[N,w]=l.useState(h),[n,j]=l.useState(null),[k,b]=l.useState(""),g=l.useRef(null);S(JSON.stringify(r)!==JSON.stringify(N),"faqs");const p=()=>m.get("/faqs").then(c);l.useEffect(p,[]);const y=t=>{const s={question_de:t.question_de,answer_de:t.answer_de,question_en:t.question_en,answer_en:t.answer_en,sort_order:t.sort_order};j(t.id),d(s),w(s),b(""),requestAnimationFrame(()=>{var a,u,x;(a=g.current)==null||a.scrollIntoView({behavior:"smooth",block:"start"}),(x=(u=g.current)==null?void 0:u.querySelector("input"))==null||x.focus({preventScroll:!0})})},f=()=>{j(null),d(h),w(h)},v=async t=>{t.preventDefault(),b("");const s={...r,sort_order:Number(r.sort_order)};try{if(n)await m.put(`/faqs/${n}`,s);else{const a=o.reduce((u,x)=>Math.max(u,Number(x.sort_order)||0),0)+10;await m.post("/faqs",{...s,sort_order:a})}i.success(n?"Frage gespeichert.":"Frage angelegt."),f(),p()}catch(a){b(a.message)}},_=async t=>{if(confirm("Diese Frage wirklich löschen?"))try{await m.delete(`/faqs/${t}`),n===t&&f(),i.success("Frage gelöscht."),p()}catch(s){i.error(`Löschen fehlgeschlagen: ${s.message}`)}},q=async t=>{const s=o;c(t);try{c(await R("faqs",t)),i.success("Reihenfolge gespeichert.")}catch(a){c(s),i.error(`Reihenfolge konnte nicht gespeichert werden: ${a.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-1 flex flex-wrap items-center justify-between gap-2",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Häufig gestellte Fragen"}),e.jsx(A,{to:"/#faq",label:"Auf der Startseite ansehen"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Diese Fragen erscheinen im FAQ-Bereich der Startseite, jeweils in der aktuell gewählten Sprache. Die 6 mitgelieferten Einträge sind die Standard-Einstellung – du kannst sie bearbeiten, löschen und beliebig neue hinzufügen. Reihenfolge am Griff links per Ziehen ändern."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Frage (DE)"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(E,{items:o,onReorder:q,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,s)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:s}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:t.question_de}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>y(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>_(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),o.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:3,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Fragen angelegt."})})})]})})]}),e.jsxs("form",{ref:g,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:n?"Frage bearbeiten":"Neue Frage"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Frage (Deutsch) *"}),e.jsx("input",{required:!0,value:r.question_de,onChange:t=>d({...r,question_de:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Antwort (Deutsch) *"}),e.jsx("textarea",{required:!0,rows:3,value:r.answer_de,onChange:t=>d({...r,answer_de:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Frage (Englisch) *"}),e.jsx("input",{required:!0,value:r.question_en,onChange:t=>d({...r,question_en:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Antwort (Englisch) *"}),e.jsx("textarea",{required:!0,rows:3,value:r.answer_en,onChange:t=>d({...r,answer_en:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),k&&e.jsx("p",{className:"text-sm text-red-600",children:k}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:n?"Speichern":"Anlegen"}),n&&e.jsx("button",{type:"button",onClick:f,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{O as default}; +import{o as F,r as l,p as S,j as e,c as m}from"./index-Cc1wEeIX.js";import{S as E,s as R}from"./SortableList-DIXFCDYS.js";import{V as A}from"./ViewOnSite-CStAY6xT.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const h={question_de:"",answer_de:"",question_en:"",answer_en:"",sort_order:0};function O(){const i=F(),[o,c]=l.useState([]),[r,d]=l.useState(h),[N,w]=l.useState(h),[n,j]=l.useState(null),[k,b]=l.useState(""),g=l.useRef(null);S(JSON.stringify(r)!==JSON.stringify(N),"faqs");const p=()=>m.get("/faqs").then(c);l.useEffect(p,[]);const y=t=>{const s={question_de:t.question_de,answer_de:t.answer_de,question_en:t.question_en,answer_en:t.answer_en,sort_order:t.sort_order};j(t.id),d(s),w(s),b(""),requestAnimationFrame(()=>{var a,u,x;(a=g.current)==null||a.scrollIntoView({behavior:"smooth",block:"start"}),(x=(u=g.current)==null?void 0:u.querySelector("input"))==null||x.focus({preventScroll:!0})})},f=()=>{j(null),d(h),w(h)},v=async t=>{t.preventDefault(),b("");const s={...r,sort_order:Number(r.sort_order)};try{if(n)await m.put(`/faqs/${n}`,s);else{const a=o.reduce((u,x)=>Math.max(u,Number(x.sort_order)||0),0)+10;await m.post("/faqs",{...s,sort_order:a})}i.success(n?"Frage gespeichert.":"Frage angelegt."),f(),p()}catch(a){b(a.message)}},_=async t=>{if(confirm("Diese Frage wirklich löschen?"))try{await m.delete(`/faqs/${t}`),n===t&&f(),i.success("Frage gelöscht."),p()}catch(s){i.error(`Löschen fehlgeschlagen: ${s.message}`)}},q=async t=>{const s=o;c(t);try{c(await R("faqs",t)),i.success("Reihenfolge gespeichert.")}catch(a){c(s),i.error(`Reihenfolge konnte nicht gespeichert werden: ${a.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-1 flex flex-wrap items-center justify-between gap-2",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Häufig gestellte Fragen"}),e.jsx(A,{to:"/#faq",label:"Auf der Startseite ansehen"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Diese Fragen erscheinen im FAQ-Bereich der Startseite, jeweils in der aktuell gewählten Sprache. Die 6 mitgelieferten Einträge sind die Standard-Einstellung – du kannst sie bearbeiten, löschen und beliebig neue hinzufügen. Reihenfolge am Griff links per Ziehen ändern."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Frage (DE)"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(E,{items:o,onReorder:q,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,s)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:s}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:t.question_de}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>y(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>_(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),o.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:3,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Fragen angelegt."})})})]})})]}),e.jsxs("form",{ref:g,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:n?"Frage bearbeiten":"Neue Frage"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Frage (Deutsch) *"}),e.jsx("input",{required:!0,value:r.question_de,onChange:t=>d({...r,question_de:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Antwort (Deutsch) *"}),e.jsx("textarea",{required:!0,rows:3,value:r.answer_de,onChange:t=>d({...r,answer_de:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Frage (Englisch) *"}),e.jsx("input",{required:!0,value:r.question_en,onChange:t=>d({...r,question_en:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Antwort (Englisch) *"}),e.jsx("textarea",{required:!0,rows:3,value:r.answer_en,onChange:t=>d({...r,answer_en:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),k&&e.jsx("p",{className:"text-sm text-red-600",children:k}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:n?"Speichern":"Anlegen"}),n&&e.jsx("button",{type:"button",onClick:f,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{O as default}; diff --git a/hifi/assets/GalleryBrandPage-C8027MHD.js b/hifi/assets/GalleryBrandPage-BhU6Rbz8.js similarity index 97% rename from hifi/assets/GalleryBrandPage-C8027MHD.js rename to hifi/assets/GalleryBrandPage-BhU6Rbz8.js index 08261cb..c72b8c0 100644 --- a/hifi/assets/GalleryBrandPage-C8027MHD.js +++ b/hifi/assets/GalleryBrandPage-BhU6Rbz8.js @@ -1 +1 @@ -import{f as m,r as n,u as g,a as u,c as p,b as h,j as a,N as b,e as f,L as d,d as y}from"./index-Tg8iNBwT.js";function v(){const{brandSlug:s}=m(),[e,i]=n.useState(null),[l,o]=n.useState(null),{t}=g(),{gallery_card_text_x:x,gallery_card_text_y:c}=u();return n.useEffect(()=>{p.get(`/gallery-brands/${s}/projects`).then(i).catch(r=>o(r))},[s]),h({title:e?t("galleryBrandPage.metaTitle")(e.brand.name):t("galleryBrandPage.metaTitleFallback"),description:e?t("galleryBrandPage.metaDescription")(e.brand.name):void 0,path:`/galerie/${s}`}),l?l.status===404?a.jsx(b,{}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:f(l,t)}):e?a.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[a.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[a.jsx(d,{to:"/galerie",className:"hover:text-brand-500",children:t("galleryBrandPage.breadcrumbGallery")})," / ",e.brand.name]}),a.jsxs("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:[e.brand.name," – ",t("galleryBrandPage.titleSuffix")]}),e.projects.length===0&&a.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:t("galleryBrandPage.empty")}),a.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:e.projects.map(r=>a.jsxs(d,{to:`/galerie/${s}/${r.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[r.cover_image_path?a.jsx("img",{src:r.cover_image_path,alt:r.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):a.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),a.jsx("span",{className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:y(x,c,{x:0,y:100}),children:r.name})]},r.id))})]}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:t("galleryBrandPage.loading")})}export{v as default}; +import{f as m,r as n,u as g,a as u,c as p,b as h,j as a,N as b,e as f,L as d,d as y}from"./index-Cc1wEeIX.js";function v(){const{brandSlug:s}=m(),[e,i]=n.useState(null),[l,o]=n.useState(null),{t}=g(),{gallery_card_text_x:x,gallery_card_text_y:c}=u();return n.useEffect(()=>{p.get(`/gallery-brands/${s}/projects`).then(i).catch(r=>o(r))},[s]),h({title:e?t("galleryBrandPage.metaTitle")(e.brand.name):t("galleryBrandPage.metaTitleFallback"),description:e?t("galleryBrandPage.metaDescription")(e.brand.name):void 0,path:`/galerie/${s}`}),l?l.status===404?a.jsx(b,{}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:f(l,t)}):e?a.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[a.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[a.jsx(d,{to:"/galerie",className:"hover:text-brand-500",children:t("galleryBrandPage.breadcrumbGallery")})," / ",e.brand.name]}),a.jsxs("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:[e.brand.name," – ",t("galleryBrandPage.titleSuffix")]}),e.projects.length===0&&a.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:t("galleryBrandPage.empty")}),a.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:e.projects.map(r=>a.jsxs(d,{to:`/galerie/${s}/${r.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[r.cover_image_path?a.jsx("img",{src:r.cover_image_path,alt:r.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):a.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),a.jsx("span",{className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:y(x,c,{x:0,y:100}),children:r.name})]},r.id))})]}):a.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:t("galleryBrandPage.loading")})}export{v as default}; diff --git a/hifi/assets/GalleryBrands-B2uVgrZq.js b/hifi/assets/GalleryBrands-7-ErMZO-.js similarity index 93% rename from hifi/assets/GalleryBrands-B2uVgrZq.js rename to hifi/assets/GalleryBrands-7-ErMZO-.js index f3f147f..8232f02 100644 --- a/hifi/assets/GalleryBrands-B2uVgrZq.js +++ b/hifi/assets/GalleryBrands-7-ErMZO-.js @@ -1 +1 @@ -import{r as l,o as R,p as M,j as e,c as m}from"./index-Tg8iNBwT.js";import{I as F}from"./ImageUploadField-Ds8_wHup.js";import{S as C,s as E}from"./SortableList-DRJ1jYgo.js";import{V as k}from"./ViewOnSite-CVVA03Ho.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const h={name:"",cover_image_path:"",sort_order:0};function V(){const[o,d]=l.useState([]),[a,c]=l.useState(h),[N,g]=l.useState(h),[s,p]=l.useState(null),[b,f]=l.useState(""),j=l.useRef(null),i=R();M(JSON.stringify(a)!==JSON.stringify(N),"gallery-brands");const x=()=>m.get("/gallery-brands").then(d);l.useEffect(()=>{x()},[]);const y=t=>{var n;const r={name:t.name,cover_image_path:t.cover_image_path||"",sort_order:t.sort_order};p(t.id),c(r),g(r),(n=j.current)==null||n.scrollIntoView({behavior:"smooth",block:"start"})},u=()=>{p(null),c(h),g(h)},v=async t=>{t.preventDefault(),f("");try{if(s)await m.put(`/gallery-brands/${s}`,a);else{const r=o.reduce((n,S)=>Math.max(n,Number(S.sort_order)||0),0)+10;await m.post("/gallery-brands",{...a,sort_order:r})}i.success(s?"Marke gespeichert.":"Marke angelegt."),u(),x()}catch(r){f(r.message)}},w=async t=>{if(confirm("Marke inkl. aller Projekte/Fotos wirklich löschen?"))try{await m.delete(`/gallery-brands/${t}`),s===t&&u(),i.success("Marke gelöscht."),x()}catch(r){i.error(`Löschen fehlgeschlagen: ${r.message}`)}},_=async t=>{const r=o;d(t);try{d(await E("gallery-brands",t)),i.success("Reihenfolge gespeichert.")}catch(n){d(r),i.error(`Reihenfolge konnte nicht gespeichert werden: ${n.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Galerie-Marken"}),e.jsx(k,{to:"/galerie"})]}),e.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:"Reihenfolge am Griff links per Ziehen ändern."}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Bild"}),e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(C,{items:o,onReorder:_,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.cover_image_path?e.jsx("img",{src:t.cover_image_path,alt:"",className:"h-10 w-10 rounded-md object-cover"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsxs("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:[t.name,e.jsx(k,{to:`/galerie/${t.slug}`,className:"ml-2"})]}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>y(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>w(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),o.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:"Noch keine Galerie-Marken angelegt."})]})]}),e.jsxs("form",{ref:j,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:s?"Marke bearbeiten":"Neue Marke"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:a.name,onChange:t=>c({...a,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(F,{value:a.cover_image_path,onChange:t=>c({...a,cover_image_path:t}),aspect:4/3,label:"Titelbild (optional)"}),b&&e.jsx("p",{className:"text-sm text-red-600",children:b}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:s?"Speichern":"Anlegen"}),s&&e.jsx("button",{type:"button",onClick:u,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{V as default}; +import{r as l,o as R,p as M,j as e,c as m}from"./index-Cc1wEeIX.js";import{I as F}from"./ImageUploadField-DYOhdPMm.js";import{S as C,s as E}from"./SortableList-DIXFCDYS.js";import{V as k}from"./ViewOnSite-CStAY6xT.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const h={name:"",cover_image_path:"",sort_order:0};function V(){const[o,d]=l.useState([]),[a,c]=l.useState(h),[N,g]=l.useState(h),[s,p]=l.useState(null),[b,f]=l.useState(""),j=l.useRef(null),i=R();M(JSON.stringify(a)!==JSON.stringify(N),"gallery-brands");const x=()=>m.get("/gallery-brands").then(d);l.useEffect(()=>{x()},[]);const y=t=>{var n;const r={name:t.name,cover_image_path:t.cover_image_path||"",sort_order:t.sort_order};p(t.id),c(r),g(r),(n=j.current)==null||n.scrollIntoView({behavior:"smooth",block:"start"})},u=()=>{p(null),c(h),g(h)},v=async t=>{t.preventDefault(),f("");try{if(s)await m.put(`/gallery-brands/${s}`,a);else{const r=o.reduce((n,S)=>Math.max(n,Number(S.sort_order)||0),0)+10;await m.post("/gallery-brands",{...a,sort_order:r})}i.success(s?"Marke gespeichert.":"Marke angelegt."),u(),x()}catch(r){f(r.message)}},w=async t=>{if(confirm("Marke inkl. aller Projekte/Fotos wirklich löschen?"))try{await m.delete(`/gallery-brands/${t}`),s===t&&u(),i.success("Marke gelöscht."),x()}catch(r){i.error(`Löschen fehlgeschlagen: ${r.message}`)}},_=async t=>{const r=o;d(t);try{d(await E("gallery-brands",t)),i.success("Reihenfolge gespeichert.")}catch(n){d(r),i.error(`Reihenfolge konnte nicht gespeichert werden: ${n.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Galerie-Marken"}),e.jsx(k,{to:"/galerie"})]}),e.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:"Reihenfolge am Griff links per Ziehen ändern."}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Bild"}),e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(C,{items:o,onReorder:_,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.cover_image_path?e.jsx("img",{src:t.cover_image_path,alt:"",className:"h-10 w-10 rounded-md object-cover"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsxs("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:[t.name,e.jsx(k,{to:`/galerie/${t.slug}`,className:"ml-2"})]}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>y(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>w(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),o.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:"Noch keine Galerie-Marken angelegt."})]})]}),e.jsxs("form",{ref:j,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:s?"Marke bearbeiten":"Neue Marke"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:a.name,onChange:t=>c({...a,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(F,{value:a.cover_image_path,onChange:t=>c({...a,cover_image_path:t}),aspect:4/3,label:"Titelbild (optional)"}),b&&e.jsx("p",{className:"text-sm text-red-600",children:b}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:s?"Speichern":"Anlegen"}),s&&e.jsx("button",{type:"button",onClick:u,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{V as default}; diff --git a/hifi/assets/GalleryOverview-0HIJlhh1.js b/hifi/assets/GalleryOverview-DhSnL2lN.js similarity index 96% rename from hifi/assets/GalleryOverview-0HIJlhh1.js rename to hifi/assets/GalleryOverview-DhSnL2lN.js index fea3961..d340b4f 100644 --- a/hifi/assets/GalleryOverview-0HIJlhh1.js +++ b/hifi/assets/GalleryOverview-DhSnL2lN.js @@ -1 +1 @@ -import{r as s,u as x,a as d,b as g,c as u,j as e,e as m,L as p,d as h}from"./index-Tg8iNBwT.js";function y(){const[r,i]=s.useState(null),[l,n]=s.useState(null),{t:a}=x(),{gallery_card_text_x:c,gallery_card_text_y:o}=d();return g({title:a("galleryOverview.metaTitle"),description:a("galleryOverview.metaDescription"),path:"/galerie"}),s.useEffect(()=>{u.get("/gallery-brands").then(i).catch(t=>n(t))},[]),e.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:a("galleryOverview.title")}),e.jsx("p",{className:"mb-8 text-neutral-600 dark:text-neutral-300",children:a("galleryOverview.intro")}),l&&e.jsx("p",{className:"text-red-600",children:typeof l=="string"?l:m(l,a)}),!r&&!l&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("galleryOverview.loading")}),r&&r.length===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("galleryOverview.empty")}),e.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:r==null?void 0:r.map(t=>e.jsxs(p,{to:`/galerie/${t.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[t.cover_image_path?e.jsx("img",{src:t.cover_image_path,alt:t.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),e.jsx("span",{className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:h(c,o,{x:0,y:100}),children:t.name})]},t.id))})]})}export{y as default}; +import{r as s,u as x,a as d,b as g,c as u,j as e,e as m,L as p,d as h}from"./index-Cc1wEeIX.js";function y(){const[r,i]=s.useState(null),[l,n]=s.useState(null),{t:a}=x(),{gallery_card_text_x:c,gallery_card_text_y:o}=d();return g({title:a("galleryOverview.metaTitle"),description:a("galleryOverview.metaDescription"),path:"/galerie"}),s.useEffect(()=>{u.get("/gallery-brands").then(i).catch(t=>n(t))},[]),e.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:a("galleryOverview.title")}),e.jsx("p",{className:"mb-8 text-neutral-600 dark:text-neutral-300",children:a("galleryOverview.intro")}),l&&e.jsx("p",{className:"text-red-600",children:typeof l=="string"?l:m(l,a)}),!r&&!l&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("galleryOverview.loading")}),r&&r.length===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("galleryOverview.empty")}),e.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:r==null?void 0:r.map(t=>e.jsxs(p,{to:`/galerie/${t.slug}`,className:"group relative block aspect-[4/3] overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[t.cover_image_path?e.jsx("img",{src:t.cover_image_path,alt:t.name,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-neutral-200 dark:bg-neutral-800"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),e.jsx("span",{className:"absolute whitespace-nowrap p-4 text-lg font-extrabold text-white",style:h(c,o,{x:0,y:100}),children:t.name})]},t.id))})]})}export{y as default}; diff --git a/hifi/assets/GalleryPhotos-_0TxVvt5.js b/hifi/assets/GalleryPhotos-CuXZZ7cQ.js similarity index 94% rename from hifi/assets/GalleryPhotos-_0TxVvt5.js rename to hifi/assets/GalleryPhotos-CuXZZ7cQ.js index 2936042..b0f3caf 100644 --- a/hifi/assets/GalleryPhotos-_0TxVvt5.js +++ b/hifi/assets/GalleryPhotos-CuXZZ7cQ.js @@ -1,3 +1,3 @@ -import{f as z,r as l,o as B,c as d,j as t,L as C}from"./index-Tg8iNBwT.js";import{S as M,s as D}from"./SortableList-DRJ1jYgo.js";import{V as G}from"./ViewOnSite-CVVA03Ho.js";import{r as L,M as A,f as I}from"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";function J(){const{projectId:m}=z(),[u,h]=l.useState([]),[c,v]=l.useState(null),[x,j]=l.useState(""),[b,w]=l.useState(!1),[$,y]=l.useState(""),p=l.useRef(null),s=B(),f=()=>d.get(`/gallery-projects/${m}/photos`).then(h);l.useEffect(()=>{f(),d.get("/gallery-projects").then(e=>v(e.find(r=>String(r.id)===String(m))||null)).catch(()=>{})},[m]);const F=async e=>{const r=Array.from(e.target.files||[]);if(r.length===0)return;j(""),w(!0);let a=u.reduce((o,i)=>Math.max(o,Number(i.sort_order)||0),0),n=0;const g=[];for(let o=0;oA)throw new Error(`zu groß (${I(i.size)}, max. 5 MB)`);const k=new FormData;k.append("file",i);const E=await d.post("/uploads",k);a+=10,await d.post("/gallery-photos",{gallery_project_id:Number(m),image_path:E.path,sort_order:a}),n++}catch(i){g.push(`${r[o].name}: ${i.message}`)}}w(!1),y(""),p.current&&(p.current.value=""),f(),g.length===0?s.success(n===1?"1 Foto hochgeladen.":`${n} Fotos hochgeladen.`):(j(`Nicht hochgeladen: +import{f as z,r as l,o as B,c as d,j as t,L as C}from"./index-Cc1wEeIX.js";import{S as M,s as D}from"./SortableList-DIXFCDYS.js";import{V as G}from"./ViewOnSite-CStAY6xT.js";import{r as L,M as A,f as I}from"./resizeImage-C6PvAwh0.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";function J(){const{projectId:m}=z(),[u,h]=l.useState([]),[c,v]=l.useState(null),[x,j]=l.useState(""),[b,w]=l.useState(!1),[$,y]=l.useState(""),p=l.useRef(null),s=B(),f=()=>d.get(`/gallery-projects/${m}/photos`).then(h);l.useEffect(()=>{f(),d.get("/gallery-projects").then(e=>v(e.find(r=>String(r.id)===String(m))||null)).catch(()=>{})},[m]);const F=async e=>{const r=Array.from(e.target.files||[]);if(r.length===0)return;j(""),w(!0);let a=u.reduce((o,i)=>Math.max(o,Number(i.sort_order)||0),0),n=0;const g=[];for(let o=0;oA)throw new Error(`zu groß (${I(i.size)}, max. 5 MB)`);const k=new FormData;k.append("file",i);const E=await d.post("/uploads",k);a+=10,await d.post("/gallery-photos",{gallery_project_id:Number(m),image_path:E.path,sort_order:a}),n++}catch(i){g.push(`${r[o].name}: ${i.message}`)}}w(!1),y(""),p.current&&(p.current.value=""),f(),g.length===0?s.success(n===1?"1 Foto hochgeladen.":`${n} Fotos hochgeladen.`):(j(`Nicht hochgeladen: ${g.join(` `)}`),s.error(`${n} hochgeladen, ${g.length} fehlgeschlagen.`))},P=(e,r)=>{h(a=>a.map(n=>n.id===e.id?{...n,caption:r}:n))},N=l.useRef(null),S=async e=>{if((e.caption||"")!==N.current)try{await d.put(`/gallery-photos/${e.id}`,{caption:e.caption,sort_order:e.sort_order}),s.success("Bildunterschrift gespeichert.")}catch(r){s.error(`Speichern fehlgeschlagen: ${r.message}`)}},_=async e=>{if(confirm("Foto wirklich entfernen?"))try{await d.delete(`/gallery-photos/${e}`),s.success("Foto entfernt."),f()}catch(r){s.error(`Entfernen fehlgeschlagen: ${r.message}`)}},R=async e=>{const r=u;h(e);try{h(await D("gallery-photos",e)),s.success("Reihenfolge gespeichert.")}catch(a){h(r),s.error(`Reihenfolge konnte nicht gespeichert werden: ${a.message}`)}};return t.jsxs("div",{children:[t.jsx("p",{className:"mb-2 text-sm",children:t.jsx(C,{to:"/admin/gallery-projects",className:"text-brand-600 hover:underline",children:"← Zurück zu den Projekten"})}),t.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[t.jsxs("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:["Fotos im Projekt",c?`: ${c.brand_name} ${c.name}`:""]}),c&&t.jsx(G,{to:`/galerie/${c.brand_slug}/${c.slug}`})]}),t.jsxs("div",{className:"mb-6 rounded-xl border border-neutral-200 bg-white p-4 dark:border-neutral-800 dark:bg-neutral-900",children:[t.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Fotos hinzufügen (Mehrfachauswahl möglich)"}),t.jsx("input",{ref:p,type:"file",multiple:!0,accept:"image/png,image/jpeg,image/webp",onChange:F,disabled:b,className:"text-sm"}),t.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"JPG, PNG oder WebP, große Fotos werden automatisch verkleinert."}),b&&t.jsx("p",{className:"mt-2 text-sm text-neutral-500","aria-live":"polite",children:$})]}),x&&t.jsx("p",{className:"mb-4 whitespace-pre-line text-sm text-red-600",children:x}),u.length>1&&t.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:"Reihenfolge am Griff per Ziehen ändern."}),t.jsx(M,{items:u,onReorder:R,as:"grid",className:"grid grid-cols-2 gap-4 sm:grid-cols-3 md:grid-cols-4",children:(e,r)=>t.jsxs("div",{className:"overflow-hidden rounded-xl border border-neutral-200 bg-white dark:border-neutral-800 dark:bg-neutral-900",children:[t.jsx("img",{src:e.image_path,alt:e.caption||"",className:"aspect-square w-full object-cover",loading:"lazy"}),t.jsxs("div",{className:"space-y-2 p-3",children:[t.jsx("input",{value:e.caption||"",onChange:a=>P(e,a.target.value),onFocus:()=>{N.current=e.caption||""},onBlur:()=>S(e),placeholder:"Bildunterschrift (optional)",className:"w-full rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900"}),t.jsxs("div",{className:"flex items-center justify-between gap-2",children:[r,t.jsx("button",{onClick:()=>_(e.id),className:"text-xs text-red-600 hover:underline",children:"Entfernen"})]})]})]})}),u.length===0&&t.jsx("p",{className:"py-6 text-center text-neutral-400",children:"Noch keine Fotos in diesem Projekt."})]})}export{J as default}; diff --git a/hifi/assets/GalleryProjectPage-BLlGc26k.js b/hifi/assets/GalleryProjectPage-CsTZdUev.js similarity index 98% rename from hifi/assets/GalleryProjectPage-BLlGc26k.js rename to hifi/assets/GalleryProjectPage-CsTZdUev.js index 801b726..5e2036a 100644 --- a/hifi/assets/GalleryProjectPage-BLlGc26k.js +++ b/hifi/assets/GalleryProjectPage-CsTZdUev.js @@ -1 +1 @@ -import{u as g,r as x,g as j,j as e,f as b,c as w,b as f,N as k,e as v,L as u,R as y}from"./index-Tg8iNBwT.js";function P({photos:l,index:s,onClose:t,onNavigate:n}){const{t:i}=g();if(x.useEffect(()=>{if(s==null)return;const r=a=>{a.key==="Escape"&&t(),a.key==="ArrowRight"&&n(1),a.key==="ArrowLeft"&&n(-1)};return window.addEventListener("keydown",r),()=>window.removeEventListener("keydown",r)},[s,t,n]),s==null)return null;const d=l[s],c=r=>r.stopPropagation();return j.createPortal(e.jsxs("div",{className:"fixed inset-0 z-[200] flex items-center justify-center bg-black/90 p-4",onClick:t,children:[e.jsx("button",{onClick:r=>{c(r),t()},"aria-label":i("lightbox.close"),className:"absolute right-4 top-4 rounded-full p-2 text-white/80 hover:bg-white/10 hover:text-white",children:e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-7 w-7",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 6l12 12M18 6 6 18"})})}),l.length>1&&e.jsx("button",{onClick:r=>{c(r),n(-1)},"aria-label":i("lightbox.previous"),className:"absolute left-2 top-1/2 -translate-y-1/2 rounded-full p-2 text-white/80 hover:bg-white/10 hover:text-white sm:left-4",children:e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-8 w-8",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m15 18-6-6 6-6"})})}),e.jsx("img",{src:d.image_path,alt:d.caption||"",onClick:c,className:"max-h-[85vh] max-w-full rounded-lg object-contain"}),l.length>1&&e.jsx("button",{onClick:r=>{c(r),n(1)},"aria-label":i("lightbox.next"),className:"absolute right-2 top-1/2 -translate-y-1/2 rounded-full p-2 text-white/80 hover:bg-white/10 hover:text-white sm:right-4",children:e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-8 w-8",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m9 18 6-6-6-6"})})}),d.caption&&e.jsx("p",{onClick:c,className:"absolute bottom-4 left-1/2 -translate-x-1/2 rounded-full bg-black/60 px-4 py-1.5 text-sm text-white",children:d.caption})]}),document.body)}function L(){const{brandSlug:l,projectSlug:s}=b(),[t,n]=x.useState(null),[i,d]=x.useState(null),[c,r]=x.useState(null),{t:a}=g();x.useEffect(()=>{w.get(`/gallery-brands/${l}/${s}/photos`).then(n).catch(o=>d(o))},[l,s]),f({title:t?`${t.project.name} – ${t.project.brand_name}`:a("galleryProjectPage.metaTitleFallback"),description:t?a("galleryProjectPage.metaDescription")(t.project.name):void 0,path:`/galerie/${l}/${s}`});const p=o=>{r(h=>{const m=t.photos.length;return(h+o+m)%m})};return i?i.status===404?e.jsx(k,{}):e.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:v(i,a)}):t?e.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[e.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[e.jsx(u,{to:"/galerie",className:"hover:text-brand-500",children:a("galleryProjectPage.breadcrumbGallery")})," /"," ",e.jsx(u,{to:`/galerie/${l}`,className:"hover:text-brand-500",children:t.project.brand_name})," / ",t.project.name]}),e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.project.name}),t.photos.length===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("galleryProjectPage.empty")}),e.jsx("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-3",children:t.photos.map((o,h)=>e.jsx(y,{index:h%6,shine:!0,className:"aspect-square overflow-hidden rounded-xl",children:e.jsx("button",{onClick:()=>r(h),className:"block h-full w-full","aria-label":o.caption||a("galleryProjectPage.enlargeImage"),children:e.jsx("img",{src:o.image_path,alt:o.caption||"",loading:"lazy",decoding:"async",className:"h-full w-full object-cover transition duration-300 hover:scale-105"})})},o.id))}),e.jsxs("div",{className:"mt-12 flex flex-col items-start gap-4 rounded-2xl border border-neutral-200 bg-white p-6 shadow-sm dark:border-neutral-800 dark:bg-neutral-900 sm:flex-row sm:items-center sm:justify-between",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"text-lg font-bold text-neutral-900 dark:text-white",children:a("galleryProjectPage.ctaTitle")}),e.jsx("p",{className:"mt-1 text-sm text-neutral-600 dark:text-neutral-300",children:a("galleryProjectPage.ctaText")})]}),e.jsx(u,{to:`/kontakt?${new URLSearchParams({topic:a("galleryProjectPage.ctaTopic")(t.project.name)}).toString()}`,className:"shrink-0 rounded-md bg-brand-500 px-5 py-3 text-sm font-semibold text-white shadow-sm hover:bg-brand-600",children:a("galleryProjectPage.ctaButton")})]}),e.jsx(P,{photos:t.photos,index:c,onClose:()=>r(null),onNavigate:p})]}):e.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:a("galleryProjectPage.loading")})}export{L as default}; +import{u as g,r as x,g as j,j as e,f as b,c as w,b as f,N as k,e as v,L as u,R as y}from"./index-Cc1wEeIX.js";function P({photos:l,index:s,onClose:t,onNavigate:n}){const{t:i}=g();if(x.useEffect(()=>{if(s==null)return;const r=a=>{a.key==="Escape"&&t(),a.key==="ArrowRight"&&n(1),a.key==="ArrowLeft"&&n(-1)};return window.addEventListener("keydown",r),()=>window.removeEventListener("keydown",r)},[s,t,n]),s==null)return null;const d=l[s],c=r=>r.stopPropagation();return j.createPortal(e.jsxs("div",{className:"fixed inset-0 z-[200] flex items-center justify-center bg-black/90 p-4",onClick:t,children:[e.jsx("button",{onClick:r=>{c(r),t()},"aria-label":i("lightbox.close"),className:"absolute right-4 top-4 rounded-full p-2 text-white/80 hover:bg-white/10 hover:text-white",children:e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-7 w-7",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 6l12 12M18 6 6 18"})})}),l.length>1&&e.jsx("button",{onClick:r=>{c(r),n(-1)},"aria-label":i("lightbox.previous"),className:"absolute left-2 top-1/2 -translate-y-1/2 rounded-full p-2 text-white/80 hover:bg-white/10 hover:text-white sm:left-4",children:e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-8 w-8",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m15 18-6-6 6-6"})})}),e.jsx("img",{src:d.image_path,alt:d.caption||"",onClick:c,className:"max-h-[85vh] max-w-full rounded-lg object-contain"}),l.length>1&&e.jsx("button",{onClick:r=>{c(r),n(1)},"aria-label":i("lightbox.next"),className:"absolute right-2 top-1/2 -translate-y-1/2 rounded-full p-2 text-white/80 hover:bg-white/10 hover:text-white sm:right-4",children:e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-8 w-8",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m9 18 6-6-6-6"})})}),d.caption&&e.jsx("p",{onClick:c,className:"absolute bottom-4 left-1/2 -translate-x-1/2 rounded-full bg-black/60 px-4 py-1.5 text-sm text-white",children:d.caption})]}),document.body)}function L(){const{brandSlug:l,projectSlug:s}=b(),[t,n]=x.useState(null),[i,d]=x.useState(null),[c,r]=x.useState(null),{t:a}=g();x.useEffect(()=>{w.get(`/gallery-brands/${l}/${s}/photos`).then(n).catch(o=>d(o))},[l,s]),f({title:t?`${t.project.name} – ${t.project.brand_name}`:a("galleryProjectPage.metaTitleFallback"),description:t?a("galleryProjectPage.metaDescription")(t.project.name):void 0,path:`/galerie/${l}/${s}`});const p=o=>{r(h=>{const m=t.photos.length;return(h+o+m)%m})};return i?i.status===404?e.jsx(k,{}):e.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:v(i,a)}):t?e.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[e.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[e.jsx(u,{to:"/galerie",className:"hover:text-brand-500",children:a("galleryProjectPage.breadcrumbGallery")})," /"," ",e.jsx(u,{to:`/galerie/${l}`,className:"hover:text-brand-500",children:t.project.brand_name})," / ",t.project.name]}),e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.project.name}),t.photos.length===0&&e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("galleryProjectPage.empty")}),e.jsx("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-3",children:t.photos.map((o,h)=>e.jsx(y,{index:h%6,shine:!0,className:"aspect-square overflow-hidden rounded-xl",children:e.jsx("button",{onClick:()=>r(h),className:"block h-full w-full","aria-label":o.caption||a("galleryProjectPage.enlargeImage"),children:e.jsx("img",{src:o.image_path,alt:o.caption||"",loading:"lazy",decoding:"async",className:"h-full w-full object-cover transition duration-300 hover:scale-105"})})},o.id))}),e.jsxs("div",{className:"mt-12 flex flex-col items-start gap-4 rounded-2xl border border-neutral-200 bg-white p-6 shadow-sm dark:border-neutral-800 dark:bg-neutral-900 sm:flex-row sm:items-center sm:justify-between",children:[e.jsxs("div",{children:[e.jsx("h2",{className:"text-lg font-bold text-neutral-900 dark:text-white",children:a("galleryProjectPage.ctaTitle")}),e.jsx("p",{className:"mt-1 text-sm text-neutral-600 dark:text-neutral-300",children:a("galleryProjectPage.ctaText")})]}),e.jsx(u,{to:`/kontakt?${new URLSearchParams({topic:a("galleryProjectPage.ctaTopic")(t.project.name)}).toString()}`,className:"shrink-0 rounded-md bg-brand-500 px-5 py-3 text-sm font-semibold text-white shadow-sm hover:bg-brand-600",children:a("galleryProjectPage.ctaButton")})]}),e.jsx(P,{photos:t.photos,index:c,onClose:()=>r(null),onNavigate:p})]}):e.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:a("galleryProjectPage.loading")})}export{L as default}; diff --git a/hifi/assets/GalleryProjects-D3Z0gSrh.js b/hifi/assets/GalleryProjects-NiVXDHl3.js similarity index 94% rename from hifi/assets/GalleryProjects-D3Z0gSrh.js rename to hifi/assets/GalleryProjects-NiVXDHl3.js index f6ba8e8..120e39c 100644 --- a/hifi/assets/GalleryProjects-D3Z0gSrh.js +++ b/hifi/assets/GalleryProjects-NiVXDHl3.js @@ -1 +1 @@ -import{r as a,o as I,p as L,j as e,L as T,c as h}from"./index-Tg8iNBwT.js";import{I as z}from"./ImageUploadField-Ds8_wHup.js";import{S as G,s as O}from"./SortableList-DRJ1jYgo.js";import{V as F}from"./ViewOnSite-CVVA03Ho.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const b={name:"",gallery_brand_id:"",cover_image_path:"",sort_order:0};function H(){const[l,x]=a.useState([]),[y,C]=a.useState([]),[s,m]=a.useState(b),[R,N]=a.useState(b),[d,v]=a.useState(null),[_,w]=a.useState(""),[o,S]=a.useState("all"),P=a.useRef(null),u=I();L(JSON.stringify(s)!==JSON.stringify(R),"gallery-projects");const p=a.useMemo(()=>o==="all"?l:l.filter(t=>String(t.gallery_brand_id)===o),[l,o]),g=o!=="all",j=()=>{h.get("/gallery-projects").then(x),h.get("/gallery-brands").then(C)};a.useEffect(j,[]);const $=t=>{var n;const r={name:t.name,gallery_brand_id:t.gallery_brand_id,cover_image_path:t.cover_image_path||"",sort_order:t.sort_order};v(t.id),m(r),N(r),(n=P.current)==null||n.scrollIntoView({behavior:"smooth",block:"start"})},k=()=>{v(null),m(b),N(b)},M=async t=>{t.preventDefault(),w("");const r={...s,gallery_brand_id:Number(s.gallery_brand_id)};try{if(d)await h.put(`/gallery-projects/${d}`,r);else{const n=l.filter(c=>Number(c.gallery_brand_id)===r.gallery_brand_id).reduce((c,i)=>Math.max(c,Number(i.sort_order)||0),0)+10;await h.post("/gallery-projects",{...r,sort_order:n})}u.success(d?"Projekt gespeichert.":"Projekt angelegt."),k(),j()}catch(n){w(n.message)}},E=async t=>{if(confirm("Projekt inkl. aller Fotos wirklich löschen?"))try{await h.delete(`/gallery-projects/${t}`),d===t&&k(),u.success("Projekt gelöscht."),j()}catch(r){u.error(`Löschen fehlgeschlagen: ${r.message}`)}},A=async t=>{const r=l,n=new Set(t.map(i=>i.id)),c=i=>[...l.filter(B=>!n.has(B.id)),...i];x(c(t));try{x(c(await O("gallery-projects",t))),u.success("Reihenfolge gespeichert.")}catch(i){x(r),u.error(`Reihenfolge konnte nicht gespeichert werden: ${i.message}`)}},f="bg-white px-4 py-2 dark:bg-neutral-950";return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Galerie-Projekte"}),e.jsx(F,{to:"/galerie"})]}),e.jsxs("div",{className:"mb-3 flex flex-wrap items-center gap-2",children:[e.jsx("label",{className:"text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Nach Marke filtern:"}),e.jsxs("select",{value:o,onChange:t=>S(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"all",children:"Alle Marken"}),y.map(t=>e.jsx("option",{value:String(t.id),children:t.name},t.id))]}),o!=="all"&&e.jsx("button",{onClick:()=>S("all"),className:"text-sm text-brand-600 hover:underline",children:"Filter zurücksetzen"}),e.jsxs("span",{className:"text-sm text-neutral-400",children:[p.length," von ",l.length]})]}),e.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:g?"Reihenfolge am Griff links per Ziehen ändern.":"Zum Sortieren erst eine Marke auswählen."}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[g&&e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Marke"}),e.jsx("th",{className:"px-4 py-2",children:"Projekt"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(G,{items:p,onReorder:A,as:"tbody",disabled:!g,className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[g&&e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:f,children:t.brand_name}),e.jsxs("td",{className:`${f} font-medium text-neutral-800 dark:text-neutral-100`,children:[t.name,e.jsx(F,{to:`/galerie/${t.brand_slug}/${t.slug}`,className:"ml-2"})]}),e.jsxs("td",{className:`${f} whitespace-nowrap text-right`,children:[e.jsx(T,{to:`/admin/gallery-projects/${t.id}/photos`,className:"mr-3 text-brand-600 hover:underline",children:"Fotos"}),e.jsx("button",{onClick:()=>$(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>E(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),p.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:l.length===0?"Noch keine Projekte angelegt.":"Keine Projekte für diese Marke."})]})]}),e.jsxs("form",{ref:P,onSubmit:M,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:d?"Projekt bearbeiten":"Neues Projekt"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Marke *"}),e.jsxs("select",{required:!0,value:s.gallery_brand_id,onChange:t=>m({...s,gallery_brand_id:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Bitte wählen…"}),y.map(t=>e.jsx("option",{value:t.id,children:t.name},t.id))]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Projektname *"}),e.jsx("input",{required:!0,placeholder:"z. B. Audi TT",value:s.name,onChange:t=>m({...s,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(z,{value:s.cover_image_path,onChange:t=>m({...s,cover_image_path:t}),aspect:4/3,label:"Titelbild (optional)"}),_&&e.jsx("p",{className:"text-sm text-red-600",children:_}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:d?"Speichern":"Anlegen"}),d&&e.jsx("button",{type:"button",onClick:k,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{H as default}; +import{r as a,o as I,p as L,j as e,L as T,c as h}from"./index-Cc1wEeIX.js";import{I as z}from"./ImageUploadField-DYOhdPMm.js";import{S as G,s as O}from"./SortableList-DIXFCDYS.js";import{V as F}from"./ViewOnSite-CStAY6xT.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const b={name:"",gallery_brand_id:"",cover_image_path:"",sort_order:0};function H(){const[l,x]=a.useState([]),[y,C]=a.useState([]),[s,m]=a.useState(b),[R,N]=a.useState(b),[d,v]=a.useState(null),[_,w]=a.useState(""),[o,S]=a.useState("all"),P=a.useRef(null),u=I();L(JSON.stringify(s)!==JSON.stringify(R),"gallery-projects");const p=a.useMemo(()=>o==="all"?l:l.filter(t=>String(t.gallery_brand_id)===o),[l,o]),g=o!=="all",j=()=>{h.get("/gallery-projects").then(x),h.get("/gallery-brands").then(C)};a.useEffect(j,[]);const $=t=>{var n;const r={name:t.name,gallery_brand_id:t.gallery_brand_id,cover_image_path:t.cover_image_path||"",sort_order:t.sort_order};v(t.id),m(r),N(r),(n=P.current)==null||n.scrollIntoView({behavior:"smooth",block:"start"})},k=()=>{v(null),m(b),N(b)},M=async t=>{t.preventDefault(),w("");const r={...s,gallery_brand_id:Number(s.gallery_brand_id)};try{if(d)await h.put(`/gallery-projects/${d}`,r);else{const n=l.filter(c=>Number(c.gallery_brand_id)===r.gallery_brand_id).reduce((c,i)=>Math.max(c,Number(i.sort_order)||0),0)+10;await h.post("/gallery-projects",{...r,sort_order:n})}u.success(d?"Projekt gespeichert.":"Projekt angelegt."),k(),j()}catch(n){w(n.message)}},E=async t=>{if(confirm("Projekt inkl. aller Fotos wirklich löschen?"))try{await h.delete(`/gallery-projects/${t}`),d===t&&k(),u.success("Projekt gelöscht."),j()}catch(r){u.error(`Löschen fehlgeschlagen: ${r.message}`)}},A=async t=>{const r=l,n=new Set(t.map(i=>i.id)),c=i=>[...l.filter(B=>!n.has(B.id)),...i];x(c(t));try{x(c(await O("gallery-projects",t))),u.success("Reihenfolge gespeichert.")}catch(i){x(r),u.error(`Reihenfolge konnte nicht gespeichert werden: ${i.message}`)}},f="bg-white px-4 py-2 dark:bg-neutral-950";return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Galerie-Projekte"}),e.jsx(F,{to:"/galerie"})]}),e.jsxs("div",{className:"mb-3 flex flex-wrap items-center gap-2",children:[e.jsx("label",{className:"text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Nach Marke filtern:"}),e.jsxs("select",{value:o,onChange:t=>S(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"all",children:"Alle Marken"}),y.map(t=>e.jsx("option",{value:String(t.id),children:t.name},t.id))]}),o!=="all"&&e.jsx("button",{onClick:()=>S("all"),className:"text-sm text-brand-600 hover:underline",children:"Filter zurücksetzen"}),e.jsxs("span",{className:"text-sm text-neutral-400",children:[p.length," von ",l.length]})]}),e.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:g?"Reihenfolge am Griff links per Ziehen ändern.":"Zum Sortieren erst eine Marke auswählen."}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[g&&e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Marke"}),e.jsx("th",{className:"px-4 py-2",children:"Projekt"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(G,{items:p,onReorder:A,as:"tbody",disabled:!g,className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[g&&e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:f,children:t.brand_name}),e.jsxs("td",{className:`${f} font-medium text-neutral-800 dark:text-neutral-100`,children:[t.name,e.jsx(F,{to:`/galerie/${t.brand_slug}/${t.slug}`,className:"ml-2"})]}),e.jsxs("td",{className:`${f} whitespace-nowrap text-right`,children:[e.jsx(T,{to:`/admin/gallery-projects/${t.id}/photos`,className:"mr-3 text-brand-600 hover:underline",children:"Fotos"}),e.jsx("button",{onClick:()=>$(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>E(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),p.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:l.length===0?"Noch keine Projekte angelegt.":"Keine Projekte für diese Marke."})]})]}),e.jsxs("form",{ref:P,onSubmit:M,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:d?"Projekt bearbeiten":"Neues Projekt"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Marke *"}),e.jsxs("select",{required:!0,value:s.gallery_brand_id,onChange:t=>m({...s,gallery_brand_id:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Bitte wählen…"}),y.map(t=>e.jsx("option",{value:t.id,children:t.name},t.id))]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Projektname *"}),e.jsx("input",{required:!0,placeholder:"z. B. Audi TT",value:s.name,onChange:t=>m({...s,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(z,{value:s.cover_image_path,onChange:t=>m({...s,cover_image_path:t}),aspect:4/3,label:"Titelbild (optional)"}),_&&e.jsx("p",{className:"text-sm text-red-600",children:_}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:d?"Speichern":"Anlegen"}),d&&e.jsx("button",{type:"button",onClick:k,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{H as default}; diff --git a/hifi/assets/HomeSections-BowTW1QH.js b/hifi/assets/HomeSections-WAiTz48-.js similarity index 98% rename from hifi/assets/HomeSections-BowTW1QH.js rename to hifi/assets/HomeSections-WAiTz48-.js index 335e62f..d642d17 100644 --- a/hifi/assets/HomeSections-BowTW1QH.js +++ b/hifi/assets/HomeSections-WAiTz48-.js @@ -1 +1 @@ -import{w as G,r as i,o as K,p as V,c as g,j as e,d as F}from"./index-Tg8iNBwT.js";import{R as X}from"./RichTextEditor-kI3KpNag.js";import{T as p}from"./TextStyleWidget-By2wExOQ.js";import{S as J}from"./SaveBar-BdqoV5a_.js";const v=[{slug:"hero",label:"Großes Titelbild (ganz oben)"},{slug:"youtube",label:"Video-Abschnitt"},{slug:"craft",label:"Handwerk"},{slug:"advice",label:"Beratung"},{slug:"insights",label:"Einblicke (Bildergalerie-Intro)"},{slug:"more",label:"Mehr als Car-Hifi"}],W=["hero","youtube"],Y=[{value:"left",label:"Links"},{value:"center",label:"Mittig"},{value:"right",label:"Rechts"}],q={left:"text-left",center:"text-center",right:"text-right"};function Q(b){const d=document.createElement("div");return d.innerHTML=b||"",d.textContent||""}function ne(){var B;const b=G(),[d,h]=i.useState(null),[s,A]=i.useState("hero"),[l,M]=i.useState("de"),[f,k]=i.useState(null),[P,j]=i.useState(!1),[y,m]=i.useState(""),[O,I]=i.useState(null),_=K(),[w,L]=i.useState(""),N=i.useRef(null),[S,$]=i.useState(!1),o=d&&f?v.map(t=>t.slug).filter(t=>JSON.stringify(d[t])!==JSON.stringify(f[t])):[];if(V(o.length>0,"home-sections"),i.useEffect(()=>{g.get("/home-sections").then(t=>{h(t),k(t)}),g.get("/site-settings").then(t=>L(t.hero_image_path||""))},[]),!d)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const r=d[s],D=W.includes(s),c=(t,a)=>{h(n=>({...n,[s]:{...n[s],[t]:a}}))},u=(t,a)=>{h(n=>({...n,[s]:{...n[s],text_align_x:t,text_align_y:a}}))},T=(t,a)=>{const n=N.current.getBoundingClientRect();return{x:Math.max(0,Math.min(100,Math.round((t-n.left)/n.width*100))),y:Math.max(0,Math.min(100,Math.round((a-n.top)/n.height*100)))}},R=t=>{t.preventDefault(),t.currentTarget.setPointerCapture(t.pointerId),$(!0);const{x:a,y:n}=T(t.clientX,t.clientY);u(a,n)},H=t=>{if(!S)return;const{x:a,y:n}=T(t.clientX,t.clientY);u(a,n)},U=t=>{$(!1),t.currentTarget.releasePointerCapture(t.pointerId)},Z=async()=>{j(!0),m("");const t=[];try{for(const a of o)await g.put(`/home-sections/${a}`,d[a]),t.push(a);I(new Date),_.success(o.length>1?`${o.length} Abschnitte gespeichert.`:"Gespeichert.")}catch(a){m(a.message),_.error(`Speichern fehlgeschlagen: ${a.message}`)}finally{t.length&&k(a=>{const n={...a};return t.forEach(E=>{n[E]=d[E]}),n}),j(!1)}},x=r[`eyebrow_${l}`]||"",C=r[`title_${l}`]||((B=v.find(t=>t.slug===s))==null?void 0:B.label)||"",z=Q(r[`body_html_${l}`]);return e.jsxs("div",{className:"max-w-3xl space-y-6",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Startseite"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Text, Position/Ausrichtung und (falls vorhanden) Button-Ziel der wichtigsten Textabschnitte auf der Startseite. Bilder, Statistik-Kacheln, Marken-Streifen, Bewertungen und FAQ werden an anderer Stelle verwaltet."})]}),e.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("div",{className:"mb-4 flex flex-wrap gap-2",children:v.map(t=>e.jsxs("button",{type:"button",onClick:()=>{A(t.slug),m("")},className:`rounded-md px-3 py-1.5 text-sm font-medium transition ${s===t.slug?"bg-brand-500 text-white":"border border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:[t.label,o.includes(t.slug)&&e.jsx("span",{className:"ml-1 text-amber-400",title:"Ungespeicherte Änderungen",children:"●"})]},t.slug))}),e.jsx("div",{className:"mb-4 flex gap-1 border-b border-neutral-200 pb-4 dark:border-neutral-800",children:[["de","Deutsch"],["en","English"]].map(([t,a])=>e.jsx("button",{type:"button",onClick:()=>M(t),className:`rounded-md px-3 py-1 text-sm font-medium transition ${l===t?"bg-neutral-800 text-white dark:bg-neutral-100 dark:text-neutral-900":"text-neutral-500 hover:bg-neutral-100 dark:text-neutral-400 dark:hover:bg-neutral-800"}`,children:a},t))}),D?e.jsxs("div",{className:"mb-5 grid gap-4 border-b border-neutral-200 pb-5 dark:border-neutral-800 sm:grid-cols-[16rem_1fr] sm:items-start",children:[e.jsxs("div",{children:[e.jsxs("div",{ref:N,className:"relative aspect-video select-none overflow-hidden rounded-xl bg-neutral-900 shadow-sm",children:[s==="hero"&&w?e.jsx("img",{src:w,alt:"",draggable:!1,className:"h-full w-full object-cover"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-gradient-to-br from-neutral-700 to-neutral-900 text-xs uppercase tracking-wide text-neutral-500",children:s==="youtube"?"Video-Hintergrund":"Titelbild"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/70 via-black/20 to-black/40"}),e.jsxs("div",{onPointerDown:R,onPointerMove:H,onPointerUp:U,style:{...F(r.text_align_x,r.text_align_y,{x:50,y:50}),touchAction:"none"},className:`absolute max-w-[85%] select-none whitespace-nowrap rounded p-2 text-center transition-colors ${S?"cursor-grabbing bg-white/10 ring-2 ring-brand-400":"cursor-grab hover:bg-white/10"}`,children:[x&&e.jsx("p",{className:"truncate text-[10px] font-semibold uppercase tracking-wide text-brand-300",children:x}),e.jsx("p",{className:"truncate text-sm font-extrabold text-white",children:C})]})]}),e.jsx("p",{className:"mt-1.5 text-center text-xs text-neutral-400",children:"Zum Verschieben ziehen"})]}),e.jsxs("div",{className:"flex flex-col gap-3 sm:pt-1",children:[e.jsxs("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:["Position:"," ",e.jsxs("span",{className:"font-mono font-semibold text-neutral-700 dark:text-neutral-200",children:[r.text_align_x,"% / ",r.text_align_y,"%"]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl waagerecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>u(0,r.text_align_y),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Links"}),e.jsx("button",{type:"button",onClick:()=>u(50,r.text_align_y),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>u(100,r.text_align_y),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Rechts"})]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl senkrecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>u(r.text_align_x,0),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Oben"}),e.jsx("button",{type:"button",onClick:()=>u(r.text_align_x,50),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>u(r.text_align_x,100),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Unten"})]})]})]})]}):e.jsxs("div",{className:"mb-5 grid gap-4 border-b border-neutral-200 pb-5 dark:border-neutral-800 sm:grid-cols-[10rem_1fr] sm:items-center",children:[e.jsx("div",{className:"aspect-square rounded-xl bg-neutral-100 dark:bg-neutral-800","aria-hidden":!0}),e.jsxs("div",{children:[e.jsxs("div",{className:`rounded-lg border border-neutral-200 p-3 dark:border-neutral-700 ${q[r.text_align]||"text-left"}`,children:[x&&e.jsx("p",{className:"mb-1 text-xs font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",children:x}),e.jsx("p",{className:"mb-1 font-bold text-neutral-900 dark:text-white",children:C}),e.jsx("p",{className:"line-clamp-2 text-xs text-neutral-500 dark:text-neutral-400",children:z||"Text erscheint hier…"})]}),e.jsx("div",{className:"mt-2 flex flex-wrap gap-2",children:Y.map(t=>e.jsx("button",{type:"button",onClick:()=>c("text_align",t.value),className:`rounded-md border px-3 py-1.5 text-sm font-medium transition ${r.text_align===t.value?"border-brand-500 bg-brand-500 text-white":"border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:t.label},t.value))})]})]}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Kurzer Vorspann (optional)"}),e.jsx("input",{value:r[`eyebrow_${l}`]||"",onChange:t=>c(`eyebrow_${l}`,t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx(p,{fieldKey:`home_sections.${s}.eyebrow`,previewText:r[`eyebrow_${l}`]||"Beispieltext"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Überschrift"}),e.jsx("input",{value:r[`title_${l}`]||"",onChange:t=>c(`title_${l}`,t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx(p,{fieldKey:`home_sections.${s}.title`,previewText:r[`title_${l}`]||"Beispieltext"})]}),e.jsx(X,{label:"Text",value:r[`body_html_${l}`]||"",onChange:t=>c(`body_html_${l}`,t)}),e.jsxs("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Beschriftung (optional)"}),e.jsx("input",{value:r[`button_label_${l}`]||"",onChange:t=>c(`button_label_${l}`,t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx(p,{fieldKey:`home_sections.${s}.button_label`,previewText:r[`button_label_${l}`]||"Beispieltext"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Ziel (Link, für beide Sprachen gleich)"}),e.jsx("input",{value:r.button_url||"",onChange:t=>c("button_url",t.target.value),placeholder:"/leistungen oder https://…",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:'Ohne Beschriftung UND Ziel wird kein Button angezeigt. Mit "/" beginnende Ziele bleiben innerhalb der Seite, alles andere öffnet extern in einem neuen Tab.'})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Schriftart (für beide Sprachen gleich)"}),e.jsxs("select",{value:r.font_family||"",onChange:t=>c("font_family",t.target.value||null),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Standard (globale Schriftart)"}),b.filter(t=>t.value).map(t=>e.jsx("option",{value:t.value,children:t.label},t.label))]})]})]}),r.updated_at&&e.jsxs("p",{className:"mt-3 text-xs text-neutral-400",children:["Zuletzt geändert: ",new Date(r.updated_at.replace(" ","T")).toLocaleString("de-DE")]}),y&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:y})]}),e.jsx(J,{dirty:o.length>0,busy:P,savedAt:O,onSave:Z,label:o.length>1?`Alle ${o.length} Abschnitte speichern`:"Speichern"})]})}export{ne as default}; +import{w as G,r as i,o as K,p as V,c as g,j as e,d as F}from"./index-Cc1wEeIX.js";import{R as X}from"./RichTextEditor-BGWsKoCk.js";import{T as p}from"./TextStyleWidget-DH0ih_Iq.js";import{S as J}from"./SaveBar-Cr-Ys8TW.js";const v=[{slug:"hero",label:"Großes Titelbild (ganz oben)"},{slug:"youtube",label:"Video-Abschnitt"},{slug:"craft",label:"Handwerk"},{slug:"advice",label:"Beratung"},{slug:"insights",label:"Einblicke (Bildergalerie-Intro)"},{slug:"more",label:"Mehr als Car-Hifi"}],W=["hero","youtube"],Y=[{value:"left",label:"Links"},{value:"center",label:"Mittig"},{value:"right",label:"Rechts"}],q={left:"text-left",center:"text-center",right:"text-right"};function Q(b){const d=document.createElement("div");return d.innerHTML=b||"",d.textContent||""}function ne(){var B;const b=G(),[d,h]=i.useState(null),[s,A]=i.useState("hero"),[l,M]=i.useState("de"),[f,k]=i.useState(null),[P,j]=i.useState(!1),[y,m]=i.useState(""),[O,I]=i.useState(null),_=K(),[w,L]=i.useState(""),N=i.useRef(null),[S,$]=i.useState(!1),o=d&&f?v.map(t=>t.slug).filter(t=>JSON.stringify(d[t])!==JSON.stringify(f[t])):[];if(V(o.length>0,"home-sections"),i.useEffect(()=>{g.get("/home-sections").then(t=>{h(t),k(t)}),g.get("/site-settings").then(t=>L(t.hero_image_path||""))},[]),!d)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const r=d[s],D=W.includes(s),c=(t,a)=>{h(n=>({...n,[s]:{...n[s],[t]:a}}))},u=(t,a)=>{h(n=>({...n,[s]:{...n[s],text_align_x:t,text_align_y:a}}))},T=(t,a)=>{const n=N.current.getBoundingClientRect();return{x:Math.max(0,Math.min(100,Math.round((t-n.left)/n.width*100))),y:Math.max(0,Math.min(100,Math.round((a-n.top)/n.height*100)))}},R=t=>{t.preventDefault(),t.currentTarget.setPointerCapture(t.pointerId),$(!0);const{x:a,y:n}=T(t.clientX,t.clientY);u(a,n)},H=t=>{if(!S)return;const{x:a,y:n}=T(t.clientX,t.clientY);u(a,n)},U=t=>{$(!1),t.currentTarget.releasePointerCapture(t.pointerId)},Z=async()=>{j(!0),m("");const t=[];try{for(const a of o)await g.put(`/home-sections/${a}`,d[a]),t.push(a);I(new Date),_.success(o.length>1?`${o.length} Abschnitte gespeichert.`:"Gespeichert.")}catch(a){m(a.message),_.error(`Speichern fehlgeschlagen: ${a.message}`)}finally{t.length&&k(a=>{const n={...a};return t.forEach(E=>{n[E]=d[E]}),n}),j(!1)}},x=r[`eyebrow_${l}`]||"",C=r[`title_${l}`]||((B=v.find(t=>t.slug===s))==null?void 0:B.label)||"",z=Q(r[`body_html_${l}`]);return e.jsxs("div",{className:"max-w-3xl space-y-6",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Startseite"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Text, Position/Ausrichtung und (falls vorhanden) Button-Ziel der wichtigsten Textabschnitte auf der Startseite. Bilder, Statistik-Kacheln, Marken-Streifen, Bewertungen und FAQ werden an anderer Stelle verwaltet."})]}),e.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("div",{className:"mb-4 flex flex-wrap gap-2",children:v.map(t=>e.jsxs("button",{type:"button",onClick:()=>{A(t.slug),m("")},className:`rounded-md px-3 py-1.5 text-sm font-medium transition ${s===t.slug?"bg-brand-500 text-white":"border border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:[t.label,o.includes(t.slug)&&e.jsx("span",{className:"ml-1 text-amber-400",title:"Ungespeicherte Änderungen",children:"●"})]},t.slug))}),e.jsx("div",{className:"mb-4 flex gap-1 border-b border-neutral-200 pb-4 dark:border-neutral-800",children:[["de","Deutsch"],["en","English"]].map(([t,a])=>e.jsx("button",{type:"button",onClick:()=>M(t),className:`rounded-md px-3 py-1 text-sm font-medium transition ${l===t?"bg-neutral-800 text-white dark:bg-neutral-100 dark:text-neutral-900":"text-neutral-500 hover:bg-neutral-100 dark:text-neutral-400 dark:hover:bg-neutral-800"}`,children:a},t))}),D?e.jsxs("div",{className:"mb-5 grid gap-4 border-b border-neutral-200 pb-5 dark:border-neutral-800 sm:grid-cols-[16rem_1fr] sm:items-start",children:[e.jsxs("div",{children:[e.jsxs("div",{ref:N,className:"relative aspect-video select-none overflow-hidden rounded-xl bg-neutral-900 shadow-sm",children:[s==="hero"&&w?e.jsx("img",{src:w,alt:"",draggable:!1,className:"h-full w-full object-cover"}):e.jsx("div",{className:"flex h-full w-full items-center justify-center bg-gradient-to-br from-neutral-700 to-neutral-900 text-xs uppercase tracking-wide text-neutral-500",children:s==="youtube"?"Video-Hintergrund":"Titelbild"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/70 via-black/20 to-black/40"}),e.jsxs("div",{onPointerDown:R,onPointerMove:H,onPointerUp:U,style:{...F(r.text_align_x,r.text_align_y,{x:50,y:50}),touchAction:"none"},className:`absolute max-w-[85%] select-none whitespace-nowrap rounded p-2 text-center transition-colors ${S?"cursor-grabbing bg-white/10 ring-2 ring-brand-400":"cursor-grab hover:bg-white/10"}`,children:[x&&e.jsx("p",{className:"truncate text-[10px] font-semibold uppercase tracking-wide text-brand-300",children:x}),e.jsx("p",{className:"truncate text-sm font-extrabold text-white",children:C})]})]}),e.jsx("p",{className:"mt-1.5 text-center text-xs text-neutral-400",children:"Zum Verschieben ziehen"})]}),e.jsxs("div",{className:"flex flex-col gap-3 sm:pt-1",children:[e.jsxs("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:["Position:"," ",e.jsxs("span",{className:"font-mono font-semibold text-neutral-700 dark:text-neutral-200",children:[r.text_align_x,"% / ",r.text_align_y,"%"]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl waagerecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>u(0,r.text_align_y),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Links"}),e.jsx("button",{type:"button",onClick:()=>u(50,r.text_align_y),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>u(100,r.text_align_y),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Rechts"})]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl senkrecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>u(r.text_align_x,0),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Oben"}),e.jsx("button",{type:"button",onClick:()=>u(r.text_align_x,50),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>u(r.text_align_x,100),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Unten"})]})]})]})]}):e.jsxs("div",{className:"mb-5 grid gap-4 border-b border-neutral-200 pb-5 dark:border-neutral-800 sm:grid-cols-[10rem_1fr] sm:items-center",children:[e.jsx("div",{className:"aspect-square rounded-xl bg-neutral-100 dark:bg-neutral-800","aria-hidden":!0}),e.jsxs("div",{children:[e.jsxs("div",{className:`rounded-lg border border-neutral-200 p-3 dark:border-neutral-700 ${q[r.text_align]||"text-left"}`,children:[x&&e.jsx("p",{className:"mb-1 text-xs font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",children:x}),e.jsx("p",{className:"mb-1 font-bold text-neutral-900 dark:text-white",children:C}),e.jsx("p",{className:"line-clamp-2 text-xs text-neutral-500 dark:text-neutral-400",children:z||"Text erscheint hier…"})]}),e.jsx("div",{className:"mt-2 flex flex-wrap gap-2",children:Y.map(t=>e.jsx("button",{type:"button",onClick:()=>c("text_align",t.value),className:`rounded-md border px-3 py-1.5 text-sm font-medium transition ${r.text_align===t.value?"border-brand-500 bg-brand-500 text-white":"border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:t.label},t.value))})]})]}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Kurzer Vorspann (optional)"}),e.jsx("input",{value:r[`eyebrow_${l}`]||"",onChange:t=>c(`eyebrow_${l}`,t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx(p,{fieldKey:`home_sections.${s}.eyebrow`,previewText:r[`eyebrow_${l}`]||"Beispieltext"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Überschrift"}),e.jsx("input",{value:r[`title_${l}`]||"",onChange:t=>c(`title_${l}`,t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx(p,{fieldKey:`home_sections.${s}.title`,previewText:r[`title_${l}`]||"Beispieltext"})]}),e.jsx(X,{label:"Text",value:r[`body_html_${l}`]||"",onChange:t=>c(`body_html_${l}`,t)}),e.jsxs("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Beschriftung (optional)"}),e.jsx("input",{value:r[`button_label_${l}`]||"",onChange:t=>c(`button_label_${l}`,t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx(p,{fieldKey:`home_sections.${s}.button_label`,previewText:r[`button_label_${l}`]||"Beispieltext"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Ziel (Link, für beide Sprachen gleich)"}),e.jsx("input",{value:r.button_url||"",onChange:t=>c("button_url",t.target.value),placeholder:"/leistungen oder https://…",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:'Ohne Beschriftung UND Ziel wird kein Button angezeigt. Mit "/" beginnende Ziele bleiben innerhalb der Seite, alles andere öffnet extern in einem neuen Tab.'})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Schriftart (für beide Sprachen gleich)"}),e.jsxs("select",{value:r.font_family||"",onChange:t=>c("font_family",t.target.value||null),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Standard (globale Schriftart)"}),b.filter(t=>t.value).map(t=>e.jsx("option",{value:t.value,children:t.label},t.label))]})]})]}),r.updated_at&&e.jsxs("p",{className:"mt-3 text-xs text-neutral-400",children:["Zuletzt geändert: ",new Date(r.updated_at.replace(" ","T")).toLocaleString("de-DE")]}),y&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:y})]}),e.jsx(J,{dirty:o.length>0,busy:P,savedAt:O,onSave:Z,label:o.length>1?`Alle ${o.length} Abschnitte speichern`:"Speichern"})]})}export{ne as default}; diff --git a/hifi/assets/ImageOptimizer-DiBozBGF.js b/hifi/assets/ImageOptimizer-BWNhyKVh.js similarity index 97% rename from hifi/assets/ImageOptimizer-DiBozBGF.js rename to hifi/assets/ImageOptimizer-BWNhyKVh.js index 47c3fe8..2e4e37b 100644 --- a/hifi/assets/ImageOptimizer-DiBozBGF.js +++ b/hifi/assets/ImageOptimizer-BWNhyKVh.js @@ -1 +1 @@ -import{r,c as u,j as e}from"./index-Tg8iNBwT.js";function h({compact:m=!1}){const[n,i]=r.useState(!1),[s,l]=r.useState(null),[d,o]=r.useState(""),[t,c]=r.useState(null);r.useEffect(()=>{u.get("/settings/compress-status").then(a=>c(a.gd_available)).catch(()=>c(!1))},[]);const b=async()=>{i(!0),o(""),l(null);try{l(await u.post("/settings/compress-uploads",{}))}catch(a){o(a.message)}finally{i(!1)}};return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:"Bilder optimieren"}),t!==null&&e.jsx("span",{className:`rounded-full px-3 py-1 text-xs font-semibold ${t?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-red-100 text-red-700 dark:bg-red-900/40 dark:text-red-300"}`,children:t?"Aktiv":"Nicht verfügbar"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:m?"Verkleinert alle bereits hochgeladenen Fotos, damit die Seite schneller lädt. Neue Bilder werden automatisch verkleinert.":"Neu hochgeladene Bilder werden automatisch verkleinert und komprimiert. Dieser Button holt das für alle bereits vorhandenen Bilder nach – nützlich, wenn die Seite durch zu hoch aufgelöste Fotos spürbar langsam lädt."}),t===!1&&e.jsx("p",{className:"mb-4 rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:'Diese Funktion braucht die PHP-Erweiterung "gd", die auf diesem Server aktuell nicht aktiv ist. Bei den meisten Hostern (auch All-Inkl) ist sie Teil jeder PHP-Version – bitte beim Hoster-Support nachfragen bzw. prüfen, ob in den Hosting-Einstellungen eine andere PHP-Version ausgewählt werden muss.'}),e.jsx("button",{type:"button",onClick:b,disabled:n||t===!1,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:n?"Optimiert… bitte warten":"Bestehende Bilder optimieren"}),d&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:d}),s&&e.jsxs("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:[s.processed," Bild(er) verkleinert: ",(s.before_bytes/1024/1024).toFixed(1)," MB"," → ",(s.after_bytes/1024/1024).toFixed(1)," MB."]})]})}export{h as I}; +import{r,c as u,j as e}from"./index-Cc1wEeIX.js";function h({compact:m=!1}){const[n,i]=r.useState(!1),[s,l]=r.useState(null),[d,o]=r.useState(""),[t,c]=r.useState(null);r.useEffect(()=>{u.get("/settings/compress-status").then(a=>c(a.gd_available)).catch(()=>c(!1))},[]);const b=async()=>{i(!0),o(""),l(null);try{l(await u.post("/settings/compress-uploads",{}))}catch(a){o(a.message)}finally{i(!1)}};return e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:"Bilder optimieren"}),t!==null&&e.jsx("span",{className:`rounded-full px-3 py-1 text-xs font-semibold ${t?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-red-100 text-red-700 dark:bg-red-900/40 dark:text-red-300"}`,children:t?"Aktiv":"Nicht verfügbar"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:m?"Verkleinert alle bereits hochgeladenen Fotos, damit die Seite schneller lädt. Neue Bilder werden automatisch verkleinert.":"Neu hochgeladene Bilder werden automatisch verkleinert und komprimiert. Dieser Button holt das für alle bereits vorhandenen Bilder nach – nützlich, wenn die Seite durch zu hoch aufgelöste Fotos spürbar langsam lädt."}),t===!1&&e.jsx("p",{className:"mb-4 rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:'Diese Funktion braucht die PHP-Erweiterung "gd", die auf diesem Server aktuell nicht aktiv ist. Bei den meisten Hostern (auch All-Inkl) ist sie Teil jeder PHP-Version – bitte beim Hoster-Support nachfragen bzw. prüfen, ob in den Hosting-Einstellungen eine andere PHP-Version ausgewählt werden muss.'}),e.jsx("button",{type:"button",onClick:b,disabled:n||t===!1,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:n?"Optimiert… bitte warten":"Bestehende Bilder optimieren"}),d&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:d}),s&&e.jsxs("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:[s.processed," Bild(er) verkleinert: ",(s.before_bytes/1024/1024).toFixed(1)," MB"," → ",(s.after_bytes/1024/1024).toFixed(1)," MB."]})]})}export{h as I}; diff --git a/hifi/assets/ImageUploadField-Ds8_wHup.js b/hifi/assets/ImageUploadField-DYOhdPMm.js similarity index 99% rename from hifi/assets/ImageUploadField-Ds8_wHup.js rename to hifi/assets/ImageUploadField-DYOhdPMm.js index ba33dd6..57a89ce 100644 --- a/hifi/assets/ImageUploadField-Ds8_wHup.js +++ b/hifi/assets/ImageUploadField-DYOhdPMm.js @@ -1,4 +1,4 @@ -import{B as mt,r as m,j as u,c as ft}from"./index-Tg8iNBwT.js";import{M as gt,f as vt}from"./resizeImage-C6PvAwh0.js";var V=!1,E,Z,k,N,_,rt,W,B,U,G,nt,H,X,st,at;function g(){if(!V){V=!0;var o=navigator.userAgent,e=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(o),t=/(Mac OS X)|(Windows)|(Linux)/.exec(o);if(H=/\b(iPhone|iP[ao]d)/.exec(o),X=/\b(iP[ao]d)/.exec(o),G=/Android/i.exec(o),st=/FBAN\/\w+;/i.exec(o),at=/Mobile/i.exec(o),nt=!!/Win64/.exec(o),e){E=e[1]?parseFloat(e[1]):e[5]?parseFloat(e[5]):NaN,E&&document&&document.documentMode&&(E=document.documentMode);var i=/(?:Trident\/(\d+.\d+))/.exec(o);rt=i?parseFloat(i[1])+4:E,Z=e[2]?parseFloat(e[2]):NaN,k=e[3]?parseFloat(e[3]):NaN,N=e[4]?parseFloat(e[4]):NaN,N?(e=/(?:Chrome\/(\d+\.\d+))/.exec(o),_=e&&e[1]?parseFloat(e[1]):NaN):_=NaN}else E=Z=k=_=N=NaN;if(t){if(t[1]){var r=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(o);W=r?parseFloat(r[1].replace("_",".")):!0}else W=!1;B=!!t[2],U=!!t[3]}else W=B=U=!1}}var Y={ie:function(){return g()||E},ieCompatibilityMode:function(){return g()||rt>E},ie64:function(){return Y.ie()&&nt},firefox:function(){return g()||Z},opera:function(){return g()||k},webkit:function(){return g()||N},safari:function(){return Y.webkit()},chrome:function(){return g()||_},windows:function(){return g()||B},osx:function(){return g()||W},linux:function(){return g()||U},iphone:function(){return g()||H},mobile:function(){return g()||H||X||G||at},nativeApp:function(){return g()||st},android:function(){return g()||G},ipad:function(){return g()||X}},wt=Y,bt=!!(typeof window<"u"&&window.document&&window.document.createElement),Ct={canUseDOM:bt},xt=Ct,ht=xt,ct;ht.canUseDOM&&(ct=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);/** +import{B as mt,r as m,j as u,c as ft}from"./index-Cc1wEeIX.js";import{M as gt,f as vt}from"./resizeImage-C6PvAwh0.js";var V=!1,E,Z,k,N,_,rt,W,B,U,G,nt,H,X,st,at;function g(){if(!V){V=!0;var o=navigator.userAgent,e=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(o),t=/(Mac OS X)|(Windows)|(Linux)/.exec(o);if(H=/\b(iPhone|iP[ao]d)/.exec(o),X=/\b(iP[ao]d)/.exec(o),G=/Android/i.exec(o),st=/FBAN\/\w+;/i.exec(o),at=/Mobile/i.exec(o),nt=!!/Win64/.exec(o),e){E=e[1]?parseFloat(e[1]):e[5]?parseFloat(e[5]):NaN,E&&document&&document.documentMode&&(E=document.documentMode);var i=/(?:Trident\/(\d+.\d+))/.exec(o);rt=i?parseFloat(i[1])+4:E,Z=e[2]?parseFloat(e[2]):NaN,k=e[3]?parseFloat(e[3]):NaN,N=e[4]?parseFloat(e[4]):NaN,N?(e=/(?:Chrome\/(\d+\.\d+))/.exec(o),_=e&&e[1]?parseFloat(e[1]):NaN):_=NaN}else E=Z=k=_=N=NaN;if(t){if(t[1]){var r=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(o);W=r?parseFloat(r[1].replace("_",".")):!0}else W=!1;B=!!t[2],U=!!t[3]}else W=B=U=!1}}var Y={ie:function(){return g()||E},ieCompatibilityMode:function(){return g()||rt>E},ie64:function(){return Y.ie()&&nt},firefox:function(){return g()||Z},opera:function(){return g()||k},webkit:function(){return g()||N},safari:function(){return Y.webkit()},chrome:function(){return g()||_},windows:function(){return g()||B},osx:function(){return g()||W},linux:function(){return g()||U},iphone:function(){return g()||H},mobile:function(){return g()||H||X||G||at},nativeApp:function(){return g()||st},android:function(){return g()||G},ipad:function(){return g()||X}},wt=Y,bt=!!(typeof window<"u"&&window.document&&window.document.createElement),Ct={canUseDOM:bt},xt=Ct,ht=xt,ct;ht.canUseDOM&&(ct=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);/** * Checks if an event is supported in the current execution environment. * * NOTE: This will not work correctly for non-generic events such as `change`, diff --git a/hifi/assets/Impressum-CFvSH0LV.js b/hifi/assets/Impressum-CIqwNdiT.js similarity index 90% rename from hifi/assets/Impressum-CFvSH0LV.js rename to hifi/assets/Impressum-CIqwNdiT.js index 6567695..b88097f 100644 --- a/hifi/assets/Impressum-CFvSH0LV.js +++ b/hifi/assets/Impressum-CIqwNdiT.js @@ -1 +1 @@ -import{r as s,c as l,b as r,j as e}from"./index-Tg8iNBwT.js";function n(){const[t,a]=s.useState(null);return s.useEffect(()=>{l.get("/legal-pages/impressum").then(a).catch(()=>{})},[]),r({title:(t==null?void 0:t.title)||"Impressum",description:"Impressum von HifiPlanet Amorbach gemäß § 5 DDG.",path:"/impressum"}),t?e.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.title}),e.jsx("div",{className:"legal-content text-sm text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:t.body_html}})]}):null}export{n as default}; +import{r as s,c as l,b as r,j as e}from"./index-Cc1wEeIX.js";function n(){const[t,a]=s.useState(null);return s.useEffect(()=>{l.get("/legal-pages/impressum").then(a).catch(()=>{})},[]),r({title:(t==null?void 0:t.title)||"Impressum",description:"Impressum von HifiPlanet Amorbach gemäß § 5 DDG.",path:"/impressum"}),t?e.jsxs("div",{className:"mx-auto max-w-3xl px-4 py-12 sm:px-6",children:[e.jsx("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:t.title}),e.jsx("div",{className:"legal-content text-sm text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:t.body_html}})]}):null}export{n as default}; diff --git a/hifi/assets/LegalSettings-BKkWnLFq.js b/hifi/assets/LegalSettings-53BO_3BR.js similarity index 95% rename from hifi/assets/LegalSettings-BKkWnLFq.js rename to hifi/assets/LegalSettings-53BO_3BR.js index 8f38979..a2c7ebf 100644 --- a/hifi/assets/LegalSettings-BKkWnLFq.js +++ b/hifi/assets/LegalSettings-53BO_3BR.js @@ -1 +1 @@ -import{r as s,c as b,j as e}from"./index-Tg8iNBwT.js";import{R as v}from"./RichTextEditor-kI3KpNag.js";const j=[{slug:"impressum",label:"Impressum"},{slug:"datenschutz",label:"Datenschutzerklärung"},{slug:"agb",label:"AGB"}];function k(){const[d,u]=s.useState(null),[r,h]=s.useState("impressum"),[c,i]=s.useState(!1),[o,n]=s.useState(""),[g,l]=s.useState(!1);if(s.useEffect(()=>{b.get("/legal-pages").then(u)},[]),!d)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const a=d[r],m=(t,f)=>{u(x=>({...x,[r]:{...x[r],[t]:f}})),l(!1)},p=async()=>{i(!0),n(""),l(!1);try{await b.put(`/legal-pages/${r}`,{title:a.title,body_html:a.body_html}),l(!0)}catch(t){n(t.message)}finally{i(!1)}};return e.jsx("div",{className:"max-w-3xl space-y-6",children:e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Rechtstexte"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Impressum, Datenschutzerklärung und AGB direkt hier pflegen, statt einen Deploy für jede Textänderung zu brauchen. Bitte bei Rechtstexten im Zweifel rechtlich beraten lassen, bevor du größere Änderungen veröffentlichst."}),e.jsx("div",{className:"mb-4 flex flex-wrap gap-2",children:j.map(t=>e.jsx("button",{type:"button",onClick:()=>{h(t.slug),l(!1),n("")},className:`rounded-md px-3 py-1.5 text-sm font-medium transition ${r===t.slug?"bg-brand-500 text-white":"border border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:t.label},t.slug))}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Überschrift"}),e.jsx("input",{value:a.title,onChange:t=>m("title",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(v,{label:"Inhalt",value:a.body_html,onChange:t=>m("body_html",t)})]}),a.updated_at&&e.jsxs("p",{className:"mt-3 text-xs text-neutral-400",children:["Zuletzt geändert: ",new Date(a.updated_at.replace(" ","T")).toLocaleString("de-DE")]}),o&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:o}),g&&e.jsx("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),e.jsx("button",{type:"button",onClick:p,disabled:c,className:"mt-4 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:c?"Speichere…":"Speichern"})]})})}export{k as default}; +import{r as s,c as b,j as e}from"./index-Cc1wEeIX.js";import{R as v}from"./RichTextEditor-BGWsKoCk.js";const j=[{slug:"impressum",label:"Impressum"},{slug:"datenschutz",label:"Datenschutzerklärung"},{slug:"agb",label:"AGB"}];function k(){const[d,u]=s.useState(null),[r,h]=s.useState("impressum"),[c,i]=s.useState(!1),[o,n]=s.useState(""),[g,l]=s.useState(!1);if(s.useEffect(()=>{b.get("/legal-pages").then(u)},[]),!d)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const a=d[r],m=(t,f)=>{u(x=>({...x,[r]:{...x[r],[t]:f}})),l(!1)},p=async()=>{i(!0),n(""),l(!1);try{await b.put(`/legal-pages/${r}`,{title:a.title,body_html:a.body_html}),l(!0)}catch(t){n(t.message)}finally{i(!1)}};return e.jsx("div",{className:"max-w-3xl space-y-6",children:e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Rechtstexte"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Impressum, Datenschutzerklärung und AGB direkt hier pflegen, statt einen Deploy für jede Textänderung zu brauchen. Bitte bei Rechtstexten im Zweifel rechtlich beraten lassen, bevor du größere Änderungen veröffentlichst."}),e.jsx("div",{className:"mb-4 flex flex-wrap gap-2",children:j.map(t=>e.jsx("button",{type:"button",onClick:()=>{h(t.slug),l(!1),n("")},className:`rounded-md px-3 py-1.5 text-sm font-medium transition ${r===t.slug?"bg-brand-500 text-white":"border border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:t.label},t.slug))}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Überschrift"}),e.jsx("input",{value:a.title,onChange:t=>m("title",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(v,{label:"Inhalt",value:a.body_html,onChange:t=>m("body_html",t)})]}),a.updated_at&&e.jsxs("p",{className:"mt-3 text-xs text-neutral-400",children:["Zuletzt geändert: ",new Date(a.updated_at.replace(" ","T")).toLocaleString("de-DE")]}),o&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:o}),g&&e.jsx("p",{className:"mt-3 text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),e.jsx("button",{type:"button",onClick:p,disabled:c,className:"mt-4 rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:c?"Speichere…":"Speichern"})]})})}export{k as default}; diff --git a/hifi/assets/Login-CRdfT-83.js b/hifi/assets/Login-C7DApxPv.js similarity index 98% rename from hifi/assets/Login-CRdfT-83.js rename to hifi/assets/Login-C7DApxPv.js index 6ea1bc5..bca3ab8 100644 --- a/hifi/assets/Login-CRdfT-83.js +++ b/hifi/assets/Login-C7DApxPv.js @@ -1 +1 @@ -import{h as N,i as v,r,j as e,k as y,l as C,m as S}from"./index-Tg8iNBwT.js";function P(){const{user:x,login:h,verifyTwoFactor:g}=N(),o=v(),[f,u]=r.useState("credentials"),[i,p]=r.useState(""),[c,w]=r.useState(""),[m,b]=r.useState(""),[s,a]=r.useState(""),[n,l]=r.useState(!1);if(x)return e.jsx(y,{to:"/admin",replace:!0});const k=async t=>{t.preventDefault(),l(!0),a("");try{(await h(i,c)).requires2fa?u("code"):o("/admin")}catch(d){a(d.message)}finally{l(!1)}},j=async t=>{t.preventDefault(),l(!0),a("");try{await g(m),o("/admin")}catch(d){a(d.message)}finally{l(!1)}};return e.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center gap-6 bg-neutral-50 px-4 dark:bg-neutral-950",children:[e.jsx("img",{src:C,alt:"HifiPlanet",className:"h-16 w-auto dark:hidden sm:h-20"}),e.jsx("img",{src:S,alt:"HifiPlanet",className:"hidden h-16 w-auto dark:block sm:h-20"}),f==="credentials"?e.jsxs("form",{onSubmit:k,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-6 text-xl font-bold text-neutral-900 dark:text-white",children:"Admin-Login"}),e.jsxs("div",{className:"mb-4",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername"}),e.jsx("input",{value:i,onChange:t=>p(t.target.value),required:!0,autoFocus:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Passwort"}),e.jsx("input",{type:"password",value:c,onChange:t=>w(t.target.value),required:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Anmelden…":"Anmelden"})]}):e.jsxs("form",{onSubmit:j,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Bestätigungscode"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Öffne die Google Authenticator App und gib den 6-stelligen Code ein. Alternativ kannst du auch einen deiner Wiederherstellungscodes verwenden."}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Code"}),e.jsx("input",{value:m,onChange:t=>b(t.target.value),required:!0,autoFocus:!0,inputMode:"numeric",placeholder:"123456",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-center text-lg tracking-widest focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Prüfe…":"Bestätigen"}),e.jsx("button",{type:"button",onClick:()=>{u("credentials"),b(""),a("")},className:"mt-3 w-full text-sm text-neutral-500 hover:underline dark:text-neutral-400",children:"Zurück zum Login"})]})]})}export{P as default}; +import{h as N,i as v,r,j as e,k as y,l as C,m as S}from"./index-Cc1wEeIX.js";function P(){const{user:x,login:h,verifyTwoFactor:g}=N(),o=v(),[f,u]=r.useState("credentials"),[i,p]=r.useState(""),[c,w]=r.useState(""),[m,b]=r.useState(""),[s,a]=r.useState(""),[n,l]=r.useState(!1);if(x)return e.jsx(y,{to:"/admin",replace:!0});const k=async t=>{t.preventDefault(),l(!0),a("");try{(await h(i,c)).requires2fa?u("code"):o("/admin")}catch(d){a(d.message)}finally{l(!1)}},j=async t=>{t.preventDefault(),l(!0),a("");try{await g(m),o("/admin")}catch(d){a(d.message)}finally{l(!1)}};return e.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center gap-6 bg-neutral-50 px-4 dark:bg-neutral-950",children:[e.jsx("img",{src:C,alt:"HifiPlanet",className:"h-16 w-auto dark:hidden sm:h-20"}),e.jsx("img",{src:S,alt:"HifiPlanet",className:"hidden h-16 w-auto dark:block sm:h-20"}),f==="credentials"?e.jsxs("form",{onSubmit:k,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-6 text-xl font-bold text-neutral-900 dark:text-white",children:"Admin-Login"}),e.jsxs("div",{className:"mb-4",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Benutzername"}),e.jsx("input",{value:i,onChange:t=>p(t.target.value),required:!0,autoFocus:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Passwort"}),e.jsx("input",{type:"password",value:c,onChange:t=>w(t.target.value),required:!0,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Anmelden…":"Anmelden"})]}):e.jsxs("form",{onSubmit:j,className:"w-full max-w-sm rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Bestätigungscode"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Öffne die Google Authenticator App und gib den 6-stelligen Code ein. Alternativ kannst du auch einen deiner Wiederherstellungscodes verwenden."}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Code"}),e.jsx("input",{value:m,onChange:t=>b(t.target.value),required:!0,autoFocus:!0,inputMode:"numeric",placeholder:"123456",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-center text-lg tracking-widest focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900"})]}),s&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:s}),e.jsx("button",{type:"submit",disabled:n,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:n?"Prüfe…":"Bestätigen"}),e.jsx("button",{type:"button",onClick:()=>{u("credentials"),b(""),a("")},className:"mt-3 w-full text-sm text-neutral-500 hover:underline dark:text-neutral-400",children:"Zurück zum Login"})]})]})}export{P as default}; diff --git a/hifi/assets/MaintenanceSettings-Dou4llm0.js b/hifi/assets/MaintenanceSettings-CgC3Xndt.js similarity index 98% rename from hifi/assets/MaintenanceSettings-Dou4llm0.js rename to hifi/assets/MaintenanceSettings-CgC3Xndt.js index 2eeb922..bc67199 100644 --- a/hifi/assets/MaintenanceSettings-Dou4llm0.js +++ b/hifi/assets/MaintenanceSettings-CgC3Xndt.js @@ -1 +1 @@ -import{r as s,c as o,j as a}from"./index-Tg8iNBwT.js";const v={global:{enabled:!1,message:""},services:{enabled:!1,message:""},vehicles:{enabled:!1,message:""}};function N(){const[l,n]=s.useState(v),[g,h]=s.useState(!0),[i,d]=s.useState(!1),[x,r]=s.useState(!1),[c,u]=s.useState("");s.useEffect(()=>{o.get("/maintenance").then(e=>{n({global:{enabled:e.global.enabled,message:e.global.message||""},services:{enabled:e.services.enabled,message:e.services.message||""},vehicles:{enabled:e.vehicles.enabled,message:e.vehicles.message||""}})}).finally(()=>h(!1))},[]);const m=(e,t,k)=>{n(b=>({...b,[e]:{...b[e],[t]:k}})),r(!1)},p=async e=>{e.preventDefault(),d(!0),u(""),r(!1);try{const t=await o.post("/maintenance",l);n({global:{enabled:t.global.enabled,message:t.global.message||""},services:{enabled:t.services.enabled,message:t.services.message||""},vehicles:{enabled:t.vehicles.enabled,message:t.vehicles.message||""}}),r(!0)}catch(t){u(t.message)}finally{d(!1)}},f=[{key:"global",title:"Gesamte Seite",hint:"Besucher sehen nur noch eine Wartungsmeldung – egal welche Seite sie aufrufen. Das Admin-Panel bleibt für dich erreichbar."},{key:"services",title:"Nur Leistungen",hint:"Nur die Leistungen-Seite zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."},{key:"vehicles",title:"Nur Fahrzeugkatalog",hint:"Nur die Fahrzeugauswahl (Marke → Modell → Pakete) zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."}];return g?a.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):a.jsxs("form",{onSubmit:p,className:"max-w-2xl space-y-6",children:[a.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:'Ist "Gesamte Seite" aktiv, gewinnt das immer – die beiden anderen Schalter spielen dann keine Rolle mehr.'}),f.map(e=>a.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[a.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[a.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:e.title}),a.jsxs("label",{className:"relative inline-flex cursor-pointer items-center",children:[a.jsx("input",{type:"checkbox",checked:l[e.key].enabled,onChange:t=>m(e.key,"enabled",t.target.checked),className:"peer sr-only"}),a.jsx("div",{className:"h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 dark:bg-neutral-700"}),a.jsx("div",{className:"absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5"})]})]}),a.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:e.hint}),a.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Eigene Nachricht (optional)"}),a.jsx("textarea",{rows:2,value:l[e.key].message,onChange:t=>m(e.key,"message",t.target.value),placeholder:"z. B. Wir aktualisieren gerade unser Angebot. Schau bald wieder vorbei!",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]},e.key)),c&&a.jsx("p",{className:"text-sm text-red-600",children:c}),x&&a.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),a.jsx("button",{type:"submit",disabled:i,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":"Speichern"})]})}export{N as default}; +import{r as s,c as o,j as a}from"./index-Cc1wEeIX.js";const v={global:{enabled:!1,message:""},services:{enabled:!1,message:""},vehicles:{enabled:!1,message:""}};function N(){const[l,n]=s.useState(v),[g,h]=s.useState(!0),[i,d]=s.useState(!1),[x,r]=s.useState(!1),[c,u]=s.useState("");s.useEffect(()=>{o.get("/maintenance").then(e=>{n({global:{enabled:e.global.enabled,message:e.global.message||""},services:{enabled:e.services.enabled,message:e.services.message||""},vehicles:{enabled:e.vehicles.enabled,message:e.vehicles.message||""}})}).finally(()=>h(!1))},[]);const m=(e,t,k)=>{n(b=>({...b,[e]:{...b[e],[t]:k}})),r(!1)},p=async e=>{e.preventDefault(),d(!0),u(""),r(!1);try{const t=await o.post("/maintenance",l);n({global:{enabled:t.global.enabled,message:t.global.message||""},services:{enabled:t.services.enabled,message:t.services.message||""},vehicles:{enabled:t.vehicles.enabled,message:t.vehicles.message||""}}),r(!0)}catch(t){u(t.message)}finally{d(!1)}},f=[{key:"global",title:"Gesamte Seite",hint:"Besucher sehen nur noch eine Wartungsmeldung – egal welche Seite sie aufrufen. Das Admin-Panel bleibt für dich erreichbar."},{key:"services",title:"Nur Leistungen",hint:"Nur die Leistungen-Seite zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."},{key:"vehicles",title:"Nur Fahrzeugkatalog",hint:"Nur die Fahrzeugauswahl (Marke → Modell → Pakete) zeigt eine Wartungsmeldung, der Rest der Website funktioniert normal."}];return g?a.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):a.jsxs("form",{onSubmit:p,className:"max-w-2xl space-y-6",children:[a.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:'Ist "Gesamte Seite" aktiv, gewinnt das immer – die beiden anderen Schalter spielen dann keine Rolle mehr.'}),f.map(e=>a.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[a.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[a.jsx("h2",{className:"font-semibold text-neutral-900 dark:text-white",children:e.title}),a.jsxs("label",{className:"relative inline-flex cursor-pointer items-center",children:[a.jsx("input",{type:"checkbox",checked:l[e.key].enabled,onChange:t=>m(e.key,"enabled",t.target.checked),className:"peer sr-only"}),a.jsx("div",{className:"h-6 w-11 rounded-full bg-neutral-200 transition peer-checked:bg-brand-500 dark:bg-neutral-700"}),a.jsx("div",{className:"absolute left-1 top-1 h-4 w-4 rounded-full bg-white transition peer-checked:translate-x-5"})]})]}),a.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:e.hint}),a.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Eigene Nachricht (optional)"}),a.jsx("textarea",{rows:2,value:l[e.key].message,onChange:t=>m(e.key,"message",t.target.value),placeholder:"z. B. Wir aktualisieren gerade unser Angebot. Schau bald wieder vorbei!",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]},e.key)),c&&a.jsx("p",{className:"text-sm text-red-600",children:c}),x&&a.jsx("p",{className:"text-sm text-green-600 dark:text-green-400",children:"Gespeichert."}),a.jsx("button",{type:"submit",disabled:i,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":"Speichern"})]})}export{N as default}; diff --git a/hifi/assets/Models-D3NVlJTw.js b/hifi/assets/Models-DiJaASky.js similarity index 94% rename from hifi/assets/Models-D3NVlJTw.js rename to hifi/assets/Models-DiJaASky.js index 121e659..cf7e5c7 100644 --- a/hifi/assets/Models-D3NVlJTw.js +++ b/hifi/assets/Models-DiJaASky.js @@ -1 +1 @@ -import{o as E,r as n,p as q,j as e,c as x}from"./index-Tg8iNBwT.js";import{I as A}from"./ImageUploadField-Ds8_wHup.js";import{T}from"./TextStyleWidget-By2wExOQ.js";import{S as z,s as L}from"./SortableList-DRJ1jYgo.js";import{V as O}from"./ViewOnSite-CVVA03Ho.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const p={name:"",brand_id:"",image_path:"",sort_order:0};function G(){const c=E(),[i,h]=n.useState([]),[v,F]=n.useState([]),[l,m]=n.useState(p),[R,y]=n.useState(p),[d,w]=n.useState(null),[_,g]=n.useState(""),[o,M]=n.useState("all"),f=n.useRef(null);q(JSON.stringify(l)!==JSON.stringify(R),"models");const u=o!=="all",j=n.useMemo(()=>o==="all"?i:i.filter(t=>String(t.brand_id)===o),[i,o]),k=()=>{x.get("/models").then(h),x.get("/brands").then(F)};n.useEffect(k,[]);const C=t=>{const r={name:t.name,brand_id:t.brand_id,image_path:t.image_path||"",sort_order:t.sort_order};w(t.id),m(r),y(r),g(""),requestAnimationFrame(()=>{var a,s,b;(a=f.current)==null||a.scrollIntoView({behavior:"smooth",block:"start"}),(b=(s=f.current)==null?void 0:s.querySelector("select, input"))==null||b.focus({preventScroll:!0})})},N=()=>{w(null),m(p),y(p)},B=async t=>{t.preventDefault(),g("");const r={...l,brand_id:Number(l.brand_id)};try{if(d)await x.put(`/models/${d}`,r);else{const a=i.filter(s=>Number(s.brand_id)===r.brand_id).reduce((s,b)=>Math.max(s,Number(b.sort_order)||0),0)+10;await x.post("/models",{...r,sort_order:a})}c.success(d?"Modell gespeichert.":"Modell angelegt."),N(),k()}catch(a){g(a.message)}},I=async t=>{if(confirm("Modell inkl. aller Pakete/Produkte wirklich löschen?"))try{await x.delete(`/models/${t}`),d===t&&N(),c.success("Modell gelöscht."),k()}catch(r){c.error(`Löschen fehlgeschlagen: ${r.message}`)}},S=(t,r)=>{const a=[...r];return t.map(s=>String(s.brand_id)===o?a.shift():s)},$=async t=>{const r=i;h(S(i,t));try{const a=await L("models",t);h(s=>S(s,a)),c.success("Reihenfolge gespeichert.")}catch(a){h(r),c.error(`Reihenfolge konnte nicht gespeichert werden: ${a.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-4 text-xl font-bold text-neutral-900 dark:text-white",children:"Modelle"}),e.jsxs("div",{className:"mb-3 flex flex-wrap items-center gap-2",children:[e.jsx("label",{className:"text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Nach Marke filtern:"}),e.jsxs("select",{value:o,onChange:t=>M(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"all",children:"Alle Marken"}),v.map(t=>e.jsx("option",{value:String(t.id),children:t.name},t.id))]}),o!=="all"&&e.jsx("button",{onClick:()=>M("all"),className:"text-sm text-brand-600 hover:underline",children:"Filter zurücksetzen"}),e.jsxs("span",{className:"text-sm text-neutral-400",children:[j.length," von ",i.length]})]}),e.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:u?"Reihenfolge am Griff links per Ziehen ändern – so erscheinen die Modelle auf der Website.":"Zum Sortieren erst eine Marke auswählen."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[u&&e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Bild"}),e.jsx("th",{className:"px-4 py-2",children:"Marke"}),e.jsx("th",{className:"px-4 py-2",children:"Modell"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(z,{items:j,onReorder:$,as:"tbody",disabled:!u,className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[u&&e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.image_path?e.jsx("img",{src:t.image_path,alt:"",className:"h-10 w-10 rounded-md object-cover"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.brand_name}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:t.name}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx(O,{to:`/fahrzeuge/${t.brand_slug}/${t.slug}`,className:"mr-3"}),e.jsx("button",{onClick:()=>C(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>I(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),j.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:u?5:4,className:"px-4 py-6 text-center text-neutral-400",children:i.length===0?"Noch keine Modelle angelegt.":"Keine Modelle für diese Marke."})})})]})})]}),e.jsxs("form",{ref:f,onSubmit:B,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:d?"Modell bearbeiten":"Neues Modell"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Marke *"}),e.jsxs("select",{required:!0,value:l.brand_id,onChange:t=>m({...l,brand_id:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Bitte wählen…"}),v.map(t=>e.jsx("option",{value:t.id,children:t.name},t.id))]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Modellname *"}),e.jsx("input",{required:!0,value:l.name,onChange:t=>m({...l,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),d&&e.jsx(T,{fieldKey:`car_models.${d}.name`,previewText:l.name||"Beispieltext"})]}),e.jsx(A,{value:l.image_path,onChange:t=>m({...l,image_path:t}),label:"Bild (optional)"}),_&&e.jsx("p",{className:"text-sm text-red-600",children:_}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:d?"Speichern":"Anlegen"}),d&&e.jsx("button",{type:"button",onClick:N,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{G as default}; +import{o as E,r as n,p as q,j as e,c as x}from"./index-Cc1wEeIX.js";import{I as A}from"./ImageUploadField-DYOhdPMm.js";import{T}from"./TextStyleWidget-DH0ih_Iq.js";import{S as z,s as L}from"./SortableList-DIXFCDYS.js";import{V as O}from"./ViewOnSite-CStAY6xT.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const p={name:"",brand_id:"",image_path:"",sort_order:0};function G(){const c=E(),[i,h]=n.useState([]),[v,F]=n.useState([]),[l,m]=n.useState(p),[R,y]=n.useState(p),[d,w]=n.useState(null),[_,g]=n.useState(""),[o,M]=n.useState("all"),f=n.useRef(null);q(JSON.stringify(l)!==JSON.stringify(R),"models");const u=o!=="all",j=n.useMemo(()=>o==="all"?i:i.filter(t=>String(t.brand_id)===o),[i,o]),k=()=>{x.get("/models").then(h),x.get("/brands").then(F)};n.useEffect(k,[]);const C=t=>{const r={name:t.name,brand_id:t.brand_id,image_path:t.image_path||"",sort_order:t.sort_order};w(t.id),m(r),y(r),g(""),requestAnimationFrame(()=>{var a,s,b;(a=f.current)==null||a.scrollIntoView({behavior:"smooth",block:"start"}),(b=(s=f.current)==null?void 0:s.querySelector("select, input"))==null||b.focus({preventScroll:!0})})},N=()=>{w(null),m(p),y(p)},B=async t=>{t.preventDefault(),g("");const r={...l,brand_id:Number(l.brand_id)};try{if(d)await x.put(`/models/${d}`,r);else{const a=i.filter(s=>Number(s.brand_id)===r.brand_id).reduce((s,b)=>Math.max(s,Number(b.sort_order)||0),0)+10;await x.post("/models",{...r,sort_order:a})}c.success(d?"Modell gespeichert.":"Modell angelegt."),N(),k()}catch(a){g(a.message)}},I=async t=>{if(confirm("Modell inkl. aller Pakete/Produkte wirklich löschen?"))try{await x.delete(`/models/${t}`),d===t&&N(),c.success("Modell gelöscht."),k()}catch(r){c.error(`Löschen fehlgeschlagen: ${r.message}`)}},S=(t,r)=>{const a=[...r];return t.map(s=>String(s.brand_id)===o?a.shift():s)},$=async t=>{const r=i;h(S(i,t));try{const a=await L("models",t);h(s=>S(s,a)),c.success("Reihenfolge gespeichert.")}catch(a){h(r),c.error(`Reihenfolge konnte nicht gespeichert werden: ${a.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-4 text-xl font-bold text-neutral-900 dark:text-white",children:"Modelle"}),e.jsxs("div",{className:"mb-3 flex flex-wrap items-center gap-2",children:[e.jsx("label",{className:"text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Nach Marke filtern:"}),e.jsxs("select",{value:o,onChange:t=>M(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"all",children:"Alle Marken"}),v.map(t=>e.jsx("option",{value:String(t.id),children:t.name},t.id))]}),o!=="all"&&e.jsx("button",{onClick:()=>M("all"),className:"text-sm text-brand-600 hover:underline",children:"Filter zurücksetzen"}),e.jsxs("span",{className:"text-sm text-neutral-400",children:[j.length," von ",i.length]})]}),e.jsx("p",{className:"mb-3 text-xs text-neutral-500 dark:text-neutral-400",children:u?"Reihenfolge am Griff links per Ziehen ändern – so erscheinen die Modelle auf der Website.":"Zum Sortieren erst eine Marke auswählen."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[u&&e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Bild"}),e.jsx("th",{className:"px-4 py-2",children:"Marke"}),e.jsx("th",{className:"px-4 py-2",children:"Modell"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(z,{items:j,onReorder:$,as:"tbody",disabled:!u,className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[u&&e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.image_path?e.jsx("img",{src:t.image_path,alt:"",className:"h-10 w-10 rounded-md object-cover"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.brand_name}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:t.name}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx(O,{to:`/fahrzeuge/${t.brand_slug}/${t.slug}`,className:"mr-3"}),e.jsx("button",{onClick:()=>C(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>I(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),j.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:u?5:4,className:"px-4 py-6 text-center text-neutral-400",children:i.length===0?"Noch keine Modelle angelegt.":"Keine Modelle für diese Marke."})})})]})})]}),e.jsxs("form",{ref:f,onSubmit:B,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:d?"Modell bearbeiten":"Neues Modell"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Marke *"}),e.jsxs("select",{required:!0,value:l.brand_id,onChange:t=>m({...l,brand_id:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Bitte wählen…"}),v.map(t=>e.jsx("option",{value:t.id,children:t.name},t.id))]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Modellname *"}),e.jsx("input",{required:!0,value:l.name,onChange:t=>m({...l,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),d&&e.jsx(T,{fieldKey:`car_models.${d}.name`,previewText:l.name||"Beispieltext"})]}),e.jsx(A,{value:l.image_path,onChange:t=>m({...l,image_path:t}),label:"Bild (optional)"}),_&&e.jsx("p",{className:"text-sm text-red-600",children:_}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:d?"Speichern":"Anlegen"}),d&&e.jsx("button",{type:"button",onClick:N,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{G as default}; diff --git a/hifi/assets/Packages-CJRPrtXw.js b/hifi/assets/Packages-N3XayAy4.js similarity index 99% rename from hifi/assets/Packages-CJRPrtXw.js rename to hifi/assets/Packages-N3XayAy4.js index e1a5798..9a8dac9 100644 --- a/hifi/assets/Packages-CJRPrtXw.js +++ b/hifi/assets/Packages-N3XayAy4.js @@ -1,4 +1,4 @@ -import{j as e,r as p,o as oe,c as S,q as at,p as lt,C as Ae,s as it,t as dt}from"./index-Tg8iNBwT.js";import{T as Se}from"./TextStyleWidget-By2wExOQ.js";import{V as ct}from"./ViewOnSite-CVVA03Ho.js";import{u as ot,a as we,s as ut,K as mt,P as xt,D as ht,c as pt,S as bt,v as gt,b as ft,d as kt,C as jt}from"./sortable.esm-DhUbHeHx.js";import{P as Be,R as vt,T as Me}from"./trash-2-CnvKO1vQ.js";import{G as Nt}from"./grip-vertical-By7l82Pv.js";import{E as _t,a as yt}from"./eye-Bf2CUjOF.js";const St=["Base","Clear","Drive","Prime","Elite","Apex","The Statement","Limitless"],wt=r=>(r+1)*10,se="rounded-md border border-neutral-300 bg-white px-3 text-sm dark:border-neutral-700 dark:bg-neutral-900",A=`${se} w-full py-2`,Z=r=>new Intl.NumberFormat("de-DE",{style:"currency",currency:"EUR"}).format(Number(r)||0);function ze(r,a){const n=r.reduce((h,l)=>h+(Number(l.scraped_price)||0),0),x=Number(a.markup_value)||0;let o=0;return a.markup_type==="fixed"?o=x:a.markup_type==="percent"&&(o=n*x/100),{subtotal:n,markup:o,total:Math.round((n+o)*100)/100}}function X({title:r,onClick:a,disabled:n,danger:x,children:o}){return e.jsx("button",{type:"button",title:r,"aria-label":r,onClick:a,disabled:n,className:`rounded p-1.5 transition disabled:opacity-40 ${x?"text-neutral-400 hover:bg-red-50 hover:text-red-600 dark:hover:bg-red-900/30":"text-neutral-400 hover:bg-neutral-100 hover:text-neutral-700 dark:hover:bg-neutral-800 dark:hover:text-neutral-200"}`,children:o})}function Te({items:r,onReorder:a,children:n}){const x=ot(we(xt,{activationConstraint:{distance:4}}),we(mt,{coordinateGetter:ut})),o=({active:h,over:l})=>{if(!l||h.id===l.id)return;const k=r.findIndex(_=>_.id===h.id),f=r.findIndex(_=>_.id===l.id);a(ft(r,k,f))};return e.jsx(ht,{sensors:x,collisionDetection:pt,onDragEnd:o,children:e.jsx(bt,{items:r.map(h=>h.id),strategy:gt,children:e.jsx("ul",{className:"divide-y divide-neutral-100 rounded-lg border border-neutral-200 dark:divide-neutral-800 dark:border-neutral-800",children:r.map(h=>e.jsx($t,{id:h.id,children:l=>n(h,l)},h.id))})})})}function $t({id:r,children:a}){const{attributes:n,listeners:x,setNodeRef:o,setActivatorNodeRef:h,transform:l,transition:k,isDragging:f}=kt({id:r}),_=e.jsx("button",{type:"button",ref:h,...n,...x,title:"Ziehen, um die Reihenfolge zu ändern","aria-label":"Reihenfolge ändern",className:"mt-0.5 cursor-grab touch-none rounded p-1 text-neutral-400 hover:bg-neutral-100 hover:text-neutral-600 active:cursor-grabbing dark:hover:bg-neutral-800",children:e.jsx(Nt,{className:"h-4 w-4"})});return e.jsx("li",{ref:o,style:{transform:jt.Transform.toString(l),transition:k,position:"relative",zIndex:f?10:void 0},className:`bg-white dark:bg-neutral-950 ${f?"shadow-lg ring-1 ring-brand-500":""}`,children:a(_)})}function Ue(r,a,n){const x=a.map((l,k)=>({...l,sort_order:(k+1)*10})),o=new Map(r.map(l=>[l.id,Number(l.sort_order)])),h=x.filter(l=>o.get(l.id)!==l.sort_order);return{next:x,persist:async()=>{for(const l of h)await n(l)}}}function Pt({products:r,form:a}){const{subtotal:n,markup:x,total:o}=ze(r,a),h=r.filter(l=>l.scraped_price==null).length;return e.jsxs("div",{className:"rounded-lg bg-neutral-50 p-3 text-sm dark:bg-neutral-950",children:[e.jsxs("div",{className:"flex justify-between text-neutral-600 dark:text-neutral-300",children:[e.jsxs("span",{children:["Bauteile (",r.length,")"]}),e.jsx("span",{children:Z(n)})]}),e.jsxs("div",{className:"flex justify-between text-neutral-600 dark:text-neutral-300",children:[e.jsxs("span",{children:["Aufschlag",a.markup_type==="percent"&&` (${Number(a.markup_value)||0} %)`]}),e.jsxs("span",{children:["+ ",Z(x)]})]}),e.jsxs("div",{className:"mt-1 flex justify-between border-t border-neutral-200 pt-1 font-semibold text-neutral-900 dark:border-neutral-800 dark:text-white",children:[e.jsx("span",{children:"Preis auf der Website"}),e.jsx("span",{children:Z(o)})]}),a.price_text&&e.jsxs("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:["Auf der Kachel steht stattdessen der Preis-Text „",a.price_text,"“."]}),h>0&&e.jsxs("p",{className:"mt-1 text-xs text-amber-700 dark:text-amber-400",children:[h===1?"1 Produkt hat":`${h} Produkte haben`," noch keinen Preis und ",h===1?"zählt":"zählen"," mit 0 €."]})]})}function Ct({packageId:r,products:a,onChange:n}){const[x,o]=p.useState(""),[h,l]=p.useState(null),[k,f]=p.useState([]),[_,E]=p.useState(null),[b,u]=p.useState(null),g=oe(),y=async()=>{const i=x.split(/\r?\n/).map(P=>P.trim()).filter(Boolean);if(!i.length)return;f([]);const v=P=>/^https:\/\/www\.audio4cars\.de\//i.test(P),N=i.filter(v),c=i.filter(P=>!v(P)),L=c.map(P=>`${P}: keine audio4cars.de-Produktseite (muss mit https://www.audio4cars.de/ beginnen)`);let D=a,W=D.reduce((P,M)=>Math.max(P,Number(M.sort_order)||0),0),T=0;l({done:0,total:N.length});for(const[P,M]of N.entries()){W+=10;try{const G=await S.post("/products",{package_id:r,source_url:M,sort_order:W});D=[...D,G],n(D),T+=1,G.scrape_status==="error"&&L.push(`${M}: angelegt, aber Preis konnte nicht gelesen werden (${G.scrape_error||"unbekannter Fehler"})`)}catch(G){c.push(M),L.push(`${M}: ${G.message}`)}l({done:P+1,total:N.length})}l(null),f(L),T>0&&g.success(T===1?"Produkt hinzugefügt.":`${T} Produkte hinzugefügt.`),L.length&&g.error(`${L.length} Link(s) mit Problemen – Details unter dem Eingabefeld.`),o(c.join(` +import{j as e,r as p,o as oe,c as S,q as at,p as lt,C as Ae,s as it,t as dt}from"./index-Cc1wEeIX.js";import{T as Se}from"./TextStyleWidget-DH0ih_Iq.js";import{V as ct}from"./ViewOnSite-CStAY6xT.js";import{u as ot,a as we,s as ut,K as mt,P as xt,D as ht,c as pt,S as bt,v as gt,b as ft,d as kt,C as jt}from"./sortable.esm-D8IvDAze.js";import{P as Be,R as vt,T as Me}from"./trash-2-UGYx0Sek.js";import{G as Nt}from"./grip-vertical-0BUKE4NU.js";import{E as _t,a as yt}from"./eye-BXFieSB3.js";const St=["Base","Clear","Drive","Prime","Elite","Apex","The Statement","Limitless"],wt=r=>(r+1)*10,se="rounded-md border border-neutral-300 bg-white px-3 text-sm dark:border-neutral-700 dark:bg-neutral-900",A=`${se} w-full py-2`,Z=r=>new Intl.NumberFormat("de-DE",{style:"currency",currency:"EUR"}).format(Number(r)||0);function ze(r,a){const n=r.reduce((h,l)=>h+(Number(l.scraped_price)||0),0),x=Number(a.markup_value)||0;let o=0;return a.markup_type==="fixed"?o=x:a.markup_type==="percent"&&(o=n*x/100),{subtotal:n,markup:o,total:Math.round((n+o)*100)/100}}function X({title:r,onClick:a,disabled:n,danger:x,children:o}){return e.jsx("button",{type:"button",title:r,"aria-label":r,onClick:a,disabled:n,className:`rounded p-1.5 transition disabled:opacity-40 ${x?"text-neutral-400 hover:bg-red-50 hover:text-red-600 dark:hover:bg-red-900/30":"text-neutral-400 hover:bg-neutral-100 hover:text-neutral-700 dark:hover:bg-neutral-800 dark:hover:text-neutral-200"}`,children:o})}function Te({items:r,onReorder:a,children:n}){const x=ot(we(xt,{activationConstraint:{distance:4}}),we(mt,{coordinateGetter:ut})),o=({active:h,over:l})=>{if(!l||h.id===l.id)return;const k=r.findIndex(_=>_.id===h.id),f=r.findIndex(_=>_.id===l.id);a(ft(r,k,f))};return e.jsx(ht,{sensors:x,collisionDetection:pt,onDragEnd:o,children:e.jsx(bt,{items:r.map(h=>h.id),strategy:gt,children:e.jsx("ul",{className:"divide-y divide-neutral-100 rounded-lg border border-neutral-200 dark:divide-neutral-800 dark:border-neutral-800",children:r.map(h=>e.jsx($t,{id:h.id,children:l=>n(h,l)},h.id))})})})}function $t({id:r,children:a}){const{attributes:n,listeners:x,setNodeRef:o,setActivatorNodeRef:h,transform:l,transition:k,isDragging:f}=kt({id:r}),_=e.jsx("button",{type:"button",ref:h,...n,...x,title:"Ziehen, um die Reihenfolge zu ändern","aria-label":"Reihenfolge ändern",className:"mt-0.5 cursor-grab touch-none rounded p-1 text-neutral-400 hover:bg-neutral-100 hover:text-neutral-600 active:cursor-grabbing dark:hover:bg-neutral-800",children:e.jsx(Nt,{className:"h-4 w-4"})});return e.jsx("li",{ref:o,style:{transform:jt.Transform.toString(l),transition:k,position:"relative",zIndex:f?10:void 0},className:`bg-white dark:bg-neutral-950 ${f?"shadow-lg ring-1 ring-brand-500":""}`,children:a(_)})}function Ue(r,a,n){const x=a.map((l,k)=>({...l,sort_order:(k+1)*10})),o=new Map(r.map(l=>[l.id,Number(l.sort_order)])),h=x.filter(l=>o.get(l.id)!==l.sort_order);return{next:x,persist:async()=>{for(const l of h)await n(l)}}}function Pt({products:r,form:a}){const{subtotal:n,markup:x,total:o}=ze(r,a),h=r.filter(l=>l.scraped_price==null).length;return e.jsxs("div",{className:"rounded-lg bg-neutral-50 p-3 text-sm dark:bg-neutral-950",children:[e.jsxs("div",{className:"flex justify-between text-neutral-600 dark:text-neutral-300",children:[e.jsxs("span",{children:["Bauteile (",r.length,")"]}),e.jsx("span",{children:Z(n)})]}),e.jsxs("div",{className:"flex justify-between text-neutral-600 dark:text-neutral-300",children:[e.jsxs("span",{children:["Aufschlag",a.markup_type==="percent"&&` (${Number(a.markup_value)||0} %)`]}),e.jsxs("span",{children:["+ ",Z(x)]})]}),e.jsxs("div",{className:"mt-1 flex justify-between border-t border-neutral-200 pt-1 font-semibold text-neutral-900 dark:border-neutral-800 dark:text-white",children:[e.jsx("span",{children:"Preis auf der Website"}),e.jsx("span",{children:Z(o)})]}),a.price_text&&e.jsxs("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:["Auf der Kachel steht stattdessen der Preis-Text „",a.price_text,"“."]}),h>0&&e.jsxs("p",{className:"mt-1 text-xs text-amber-700 dark:text-amber-400",children:[h===1?"1 Produkt hat":`${h} Produkte haben`," noch keinen Preis und ",h===1?"zählt":"zählen"," mit 0 €."]})]})}function Ct({packageId:r,products:a,onChange:n}){const[x,o]=p.useState(""),[h,l]=p.useState(null),[k,f]=p.useState([]),[_,E]=p.useState(null),[b,u]=p.useState(null),g=oe(),y=async()=>{const i=x.split(/\r?\n/).map(P=>P.trim()).filter(Boolean);if(!i.length)return;f([]);const v=P=>/^https:\/\/www\.audio4cars\.de\//i.test(P),N=i.filter(v),c=i.filter(P=>!v(P)),L=c.map(P=>`${P}: keine audio4cars.de-Produktseite (muss mit https://www.audio4cars.de/ beginnen)`);let D=a,W=D.reduce((P,M)=>Math.max(P,Number(M.sort_order)||0),0),T=0;l({done:0,total:N.length});for(const[P,M]of N.entries()){W+=10;try{const G=await S.post("/products",{package_id:r,source_url:M,sort_order:W});D=[...D,G],n(D),T+=1,G.scrape_status==="error"&&L.push(`${M}: angelegt, aber Preis konnte nicht gelesen werden (${G.scrape_error||"unbekannter Fehler"})`)}catch(G){c.push(M),L.push(`${M}: ${G.message}`)}l({done:P+1,total:N.length})}l(null),f(L),T>0&&g.success(T===1?"Produkt hinzugefügt.":`${T} Produkte hinzugefügt.`),L.length&&g.error(`${L.length} Link(s) mit Problemen – Details unter dem Eingabefeld.`),o(c.join(` `))},j=async i=>{E(i.id);try{const v=await S.post(`/products/${i.id}/refresh-price`,{});n(a.map(N=>N.id===i.id?v:N)),v.scrape_status==="error"?g.error(`Preis konnte nicht gelesen werden: ${v.scrape_error||"unbekannter Fehler"}`):g.success("Name und Preis aktualisiert.")}catch(v){f([`Preis konnte nicht aktualisiert werden: ${v.message}`]),g.error(`Preis konnte nicht aktualisiert werden: ${v.message}`)}finally{E(null)}},V=async i=>{if(confirm(`Produkt "${i.name_override||i.scraped_name||i.source_url}" aus dem Paket entfernen?`)){try{await S.delete(`/products/${i.id}`)}catch(v){g.error(`Entfernen fehlgeschlagen: ${v.message}`);return}n(a.filter(v=>v.id!==i.id)),g.success("Produkt entfernt.")}},B=async(i,v)=>{const N=v.trim()||null;try{await S.put(`/products/${i.id}`,{source_url:i.source_url,name_override:N,sort_order:i.sort_order})}catch(c){g.error(`Name konnte nicht gespeichert werden: ${c.message}`);return}n(a.map(c=>c.id===i.id?{...c,name_override:N}:c)),u(null),g.success("Anzeigename gespeichert.")},z=async i=>{const{next:v,persist:N}=Ue(a,i,c=>S.put(`/products/${c.id}`,{source_url:c.source_url,name_override:c.name_override,sort_order:c.sort_order}));n(v);try{await N()}catch(c){n(a),f([`Reihenfolge konnte nicht gespeichert werden: ${c.message}`]),g.error(`Reihenfolge konnte nicht gespeichert werden: ${c.message}`)}};return e.jsxs("div",{children:[e.jsxs("h4",{className:"mb-2 text-sm font-semibold text-neutral-700 dark:text-neutral-300",children:["Produkte ",e.jsx("span",{className:"font-normal text-neutral-400",children:"– erscheinen als Stichpunkte auf der Kachel"})]}),a.length>0&&e.jsx(Te,{items:a,onReorder:z,children:(i,v)=>e.jsxs("div",{className:"flex items-start gap-2 px-2 py-2 text-sm",children:[v,e.jsxs("div",{className:"min-w-0 flex-1",children:[(b==null?void 0:b.id)===i.id?e.jsxs("form",{className:"flex gap-2",onSubmit:N=>{N.preventDefault(),B(i,b.value)},children:[e.jsx("input",{autoFocus:!0,value:b.value,onChange:N=>u({...b,value:N.target.value}),placeholder:i.scraped_name||"Anzeigename",className:`${se} w-full py-1`}),e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-3 text-xs font-semibold text-white hover:bg-brand-600",children:"OK"}),e.jsx("button",{type:"button",onClick:()=>u(null),className:"text-xs text-neutral-500 hover:underline",children:"Abbrechen"})]}):e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:i.name_override||i.scraped_name||"Name konnte nicht gelesen werden"}),e.jsx("a",{href:i.source_url,target:"_blank",rel:"noreferrer",className:"block truncate text-xs text-neutral-400 hover:text-brand-600",children:i.source_url.replace(/^https?:\/\/(www\.)?/,"")}),i.name_override&&i.scraped_name&&e.jsxs("p",{className:"text-xs text-neutral-400",children:["Original: ",i.scraped_name]}),i.scrape_status==="error"&&e.jsx("p",{className:"text-xs text-red-600",children:i.scrape_error})]}),e.jsx("span",{className:"whitespace-nowrap pt-0.5 font-medium text-neutral-700 dark:text-neutral-200",children:i.scraped_price!=null?Z(i.scraped_price):"–"}),e.jsxs("div",{className:"flex shrink-0 items-center",children:[e.jsx(X,{title:"Anzeigenamen ändern",onClick:()=>u({id:i.id,value:i.name_override||""}),children:e.jsx(Be,{className:"h-3.5 w-3.5"})}),e.jsx(X,{title:"Name und Preis neu abrufen",onClick:()=>j(i),disabled:_===i.id,children:e.jsx(vt,{className:`h-3.5 w-3.5 ${_===i.id?"animate-spin":""}`})}),e.jsx(X,{title:"Aus dem Paket entfernen",danger:!0,onClick:()=>V(i),children:e.jsx(Me,{className:"h-3.5 w-3.5"})})]})]})}),e.jsxs("div",{className:"mt-2",children:[e.jsx("textarea",{rows:2,value:x,onChange:i=>o(i.target.value),disabled:!!h,placeholder:"audio4cars.de-Links einfügen – auch mehrere, einer pro Zeile",className:A}),e.jsxs("div",{className:"mt-1 flex flex-wrap items-center gap-2",children:[e.jsx("button",{type:"button",onClick:y,disabled:!!h||!x.trim(),className:"rounded-md border border-brand-500 px-3 py-1.5 text-sm font-semibold text-brand-600 hover:bg-brand-50 disabled:opacity-50 dark:hover:bg-brand-900/20",children:"Produkte hinzufügen"}),h&&e.jsxs("span",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:["Name und Preis werden abgerufen … ",h.done,"/",h.total]})]}),k.map(i=>e.jsx("p",{className:"mt-1 text-xs text-red-600",children:i},i))]})]})}const Ie={name:"",price:"",description:"",name_en:"",description_en:""};function $e({initial:r,submitLabel:a,onSubmit:n,onCancel:x}){const[o,h]=p.useState(r),[l,k]=p.useState(""),[f,_]=p.useState(!1),E=async b=>{b.preventDefault(),_(!0),k("");try{await n({...o,name:o.name.trim(),price:Number(o.price)||0,description:o.description.trim()||null,name_en:(o.name_en||"").trim(),description_en:(o.description_en||"").trim()}),x||h(Ie)}catch(u){k(u.message)}finally{_(!1)}};return e.jsxs("form",{onSubmit:E,className:"space-y-2",children:[e.jsxs("div",{className:"flex gap-2",children:[e.jsx("input",{required:!0,value:o.name,onChange:b=>h({...o,name:b.target.value}),placeholder:"Upgrade, z. B. Türdämmung vorne",className:`${se} min-w-0 flex-1 py-2`}),e.jsx("input",{required:!0,type:"number",step:"0.01",min:"0",value:o.price,onChange:b=>h({...o,price:b.target.value}),placeholder:"Preis €",className:`${se} w-28 shrink-0 py-2`})]}),e.jsx("input",{value:o.description||"",onChange:b=>h({...o,description:b.target.value}),placeholder:"Kurze Beschreibung (optional)",className:A}),e.jsxs("details",{open:!!(r.name_en||r.description_en),children:[e.jsx("summary",{className:"cursor-pointer select-none text-xs text-neutral-500 hover:text-neutral-700 dark:text-neutral-400 dark:hover:text-neutral-200",children:"Englisch (optional – leer = deutscher Text)"}),e.jsxs("div",{className:"mt-2 space-y-2",children:[e.jsx("input",{value:o.name_en||"",onChange:b=>h({...o,name_en:b.target.value}),placeholder:"Name auf Englisch, z. B. Front door insulation",className:A}),e.jsx("input",{value:o.description_en||"",onChange:b=>h({...o,description_en:b.target.value}),placeholder:"Beschreibung auf Englisch (optional)",className:A})]})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("button",{type:"submit",disabled:f,className:"rounded-md border border-brand-500 px-3 py-1.5 text-sm font-semibold text-brand-600 hover:bg-brand-50 disabled:opacity-50 dark:hover:bg-brand-900/20",children:a}),x&&e.jsx("button",{type:"button",onClick:x,className:"text-sm text-neutral-500 hover:underline",children:"Abbrechen"}),l&&e.jsx("span",{className:"text-xs text-red-600",children:l})]})]})}function Et({packageId:r,upgrades:a,onChange:n}){const[x,o]=p.useState(null),[h,l]=p.useState(""),k=oe(),f=async u=>{const g=a.reduce((V,B)=>Math.max(V,Number(B.sort_order)||0),0)+10,y={...u,package_id:r,sort_order:g},j=await S.post("/package-upgrades",y);n([...a,{...y,id:j.id}]),k.success(`Upgrade „${u.name}“ hinzugefügt.`)},_=async(u,g)=>{const y={...g,sort_order:u.sort_order};await S.put(`/package-upgrades/${u.id}`,y),n(a.map(j=>j.id===u.id?{...j,...y}:j)),o(null),k.success("Upgrade gespeichert.")},E=async u=>{if(confirm(`Upgrade "${u.name}" löschen?`)){try{await S.delete(`/package-upgrades/${u.id}`)}catch(g){k.error(`Löschen fehlgeschlagen: ${g.message}`);return}n(a.filter(g=>g.id!==u.id)),k.success(`Upgrade „${u.name}“ gelöscht.`)}},b=async u=>{const{next:g,persist:y}=Ue(a,u,j=>S.put(`/package-upgrades/${j.id}`,{name:j.name,description:j.description,price:j.price,sort_order:j.sort_order,name_en:j.name_en||"",description_en:j.description_en||""}));n(g);try{await y()}catch(j){n(a),l(`Reihenfolge konnte nicht gespeichert werden: ${j.message}`),k.error(`Reihenfolge konnte nicht gespeichert werden: ${j.message}`)}};return e.jsxs("div",{children:[e.jsxs("h4",{className:"mb-2 text-sm font-semibold text-neutral-700 dark:text-neutral-300",children:["Upgrades ",e.jsx("span",{className:"font-normal text-neutral-400",children:"– wählbar im Kontaktformular, nicht auf der Kachel"})]}),a.length>0&&e.jsx("div",{className:"mb-2",children:e.jsx(Te,{items:a,onReorder:b,children:(u,g)=>x===u.id?e.jsx("div",{className:"p-2",children:e.jsx($e,{initial:{name:u.name,price:u.price,description:u.description||"",name_en:u.name_en||"",description_en:u.description_en||""},submitLabel:"Speichern",onSubmit:y=>_(u,y),onCancel:()=>o(null)})}):e.jsxs("div",{className:"flex items-start gap-2 px-2 py-2 text-sm",children:[g,e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:u.name}),u.description&&e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:u.description}),u.name_en&&e.jsxs("p",{className:"text-xs text-neutral-400",children:["EN: ",u.name_en]})]}),e.jsxs("span",{className:"whitespace-nowrap pt-0.5 font-medium text-neutral-700 dark:text-neutral-200",children:["+ ",Z(u.price)]}),e.jsxs("div",{className:"flex shrink-0 items-center",children:[e.jsx(X,{title:"Bearbeiten",onClick:()=>o(u.id),children:e.jsx(Be,{className:"h-3.5 w-3.5"})}),e.jsx(X,{title:"Löschen",danger:!0,onClick:()=>E(u),children:e.jsx(Me,{className:"h-3.5 w-3.5"})})]})]})})}),h&&e.jsx("p",{className:"mb-1 text-xs text-red-600",children:h}),e.jsx($e,{initial:Ie,submitLabel:"Upgrade hinzufügen",onSubmit:f})]})}const Le=[{value:"",label:"Keine"},{value:"recommended",label:"Empfohlen"},{value:"popular",label:"Am beliebtesten"},{value:"tip",label:"Tipp"},{value:"coming_soon",label:"Coming soon"},{value:"custom",label:"Eigener Text …"}],Rt=(r,a)=>{var n;return r==="custom"?a:(n=Le.find(x=>x.value===r&&x.value))==null?void 0:n.label},de=r=>({description:r.description||"",markup_type:r.markup_type||"none",markup_value:r.markup_value||0,icon_name:r.icon_name||"",tagline:r.tagline||"",price_text:r.price_text||"",description_en:r.description_en||"",tagline_en:r.tagline_en||"",price_text_en:r.price_text_en||"",badge:r.badge||"",badge_text:r.badge_text||"",video_url:r.video_url||"",sort_order:r.sort_order??0}),At=r=>({description:"",markup_type:"none",markup_value:0,icon_name:"",tagline:"",price_text:"",description_en:"",tagline_en:"",price_text_en:"",badge:"",badge_text:"",video_url:"",sort_order:wt(r)}),Bt=["description","markup_type","markup_value","icon_name","tagline","price_text","badge","badge_text","video_url","sort_order","description_en","tagline_en","price_text_en"];function Pe({children:r}){return e.jsxs("details",{className:"mt-1",children:[e.jsx("summary",{className:"cursor-pointer select-none text-xs text-neutral-400 hover:text-neutral-600 dark:hover:text-neutral-300",children:"Erweitert: Schriftstil"}),r]})}const ne=r=>{if(!r.existing)return r.checked;const a=de(r.existing);return Bt.some(n=>String(a[n])!==String(r.form[n]))};function ce({tone:r="brand",children:a}){const n={brand:"bg-brand-100 text-brand-700 dark:bg-brand-900/40 dark:text-brand-400",amber:"bg-amber-100 text-amber-800 dark:bg-amber-900/40 dark:text-amber-300"};return e.jsx("span",{className:`rounded-full px-2 py-0.5 text-xs font-semibold ${n[r]}`,children:a})}function De({badge:r,text:a}){const n=Rt(r,a);return n?e.jsx(ce,{children:n}):null}function Ke({pkg:r,busy:a,onToggle:n}){return e.jsxs("button",{type:"button",onClick:()=>n(r),disabled:a,title:r.is_hidden?"Wieder auf der Website anzeigen":"Auf der Website ausblenden",className:`inline-flex items-center gap-1.5 rounded-full border px-2.5 py-1 text-xs font-semibold transition disabled:opacity-50 ${r.is_hidden?"border-amber-300 bg-amber-50 text-amber-800 hover:bg-amber-100 dark:border-amber-700 dark:bg-amber-900/30 dark:text-amber-300":"border-neutral-300 text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:[r.is_hidden?e.jsx(_t,{className:"h-3.5 w-3.5"}):e.jsx(yt,{className:"h-3.5 w-3.5"}),r.is_hidden?"Ausgeblendet":"Sichtbar"]})}const Y=(r,a)=>{const n=a.filter(l=>l.car_model_id===r).slice().sort((l,k)=>l.sort_order-k.sort_order||l.name.localeCompare(k.name)),x=new Set,o=St.map((l,k)=>{const f=n.find(_=>!x.has(_.id)&&_.name.trim().toLowerCase()===l.toLowerCase());return f&&x.add(f.id),{key:`tier-${k}`,tierName:l,existing:f||null,checked:!!f,form:f?de(f):At(k)}}),h=n.filter(l=>!x.has(l.id)).map(l=>({key:`legacy-${l.id}`,tierName:null,existing:l,checked:!0,form:de(l)}));return[...o,...h]},Ce=r=>{r.target.style.height="auto",r.target.style.height=`${r.target.scrollHeight}px`},Ee=r=>r.reduce((a,n)=>{var x;return(a[x=n.package_id]||(a[x]=[])).push(n),a},{}),Re=[];function Mt({row:r,open:a,products:n,upgrades:x,itemsLoaded:o,saving:h,error:l,visibilityBusy:k,descriptionRef:f,onToggleOpen:_,onToggleCreate:E,onChangeForm:b,onBold:u,onToggleVisibility:g,onDelete:y,onProductsChange:j,onUpgradesChange:V}){const B=r.tierName??r.existing.name,z=!!r.existing||r.checked,i=r.existing&&ne(r),{total:v}=ze(n,r.form);let N=null;return r.existing&&(r.form.price_text?N=`„${r.form.price_text}“`:N=o?Z(v):"…"),e.jsxs("div",{id:r.existing?`paket-${r.existing.id}`:void 0,className:"scroll-mt-4 border-t border-neutral-100 dark:border-neutral-800",children:[e.jsxs("div",{onClick:z?_:void 0,className:`flex flex-wrap items-center gap-x-3 gap-y-2 px-4 py-3 ${z?"cursor-pointer hover:bg-neutral-50 dark:hover:bg-neutral-800/40":""} ${!r.existing&&!r.checked?"opacity-70":""}`,children:[z?a?e.jsx(it,{className:"h-4 w-4 shrink-0 text-neutral-400"}):e.jsx(dt,{className:"h-4 w-4 shrink-0 text-neutral-400"}):e.jsx("span",{className:"w-4 shrink-0"}),!r.existing&&e.jsx("input",{type:"checkbox",checked:r.checked,disabled:h,title:"Paket für dieses Modell anlegen",onClick:c=>c.stopPropagation(),onChange:c=>E(c.target.checked),className:"h-5 w-5 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),e.jsx("span",{className:"font-semibold text-neutral-900 dark:text-white",children:B}),r.tierName===null&&e.jsx("span",{className:"text-xs text-neutral-400",children:"(alter Name)"}),!r.existing&&!r.checked&&e.jsx("span",{className:"text-xs text-neutral-400",children:"nicht angelegt – anhaken zum Anlegen"}),!r.existing&&r.checked&&e.jsx(ce,{children:"Neu – wird mit „Alle speichern“ angelegt"}),e.jsx(De,{badge:r.form.badge,text:r.form.badge_text}),r.form.video_url&&e.jsx(Ae,{className:"h-4 w-4 text-red-500","aria-label":"Mit Video-Link"}),i&&e.jsx(ce,{tone:"amber",children:"● ungespeichert"}),r.existing&&e.jsxs("span",{className:"ml-auto flex flex-wrap items-center gap-3 text-sm",onClick:c=>c.stopPropagation(),children:[e.jsxs("span",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:[n.length," ",n.length===1?"Produkt":"Produkte"," · ",x.length," ",x.length===1?"Upgrade":"Upgrades"]}),e.jsx("span",{className:"min-w-[90px] text-right font-semibold text-neutral-800 dark:text-neutral-100",children:N}),e.jsx(Ke,{pkg:r.existing,busy:k,onToggle:g})]})]}),a&&z&&e.jsxs("div",{className:"grid gap-6 px-4 pb-6 sm:pl-11 lg:grid-cols-2",children:[e.jsxs("div",{className:"space-y-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung"}),e.jsx("p",{className:"mb-1 text-xs text-neutral-500 dark:text-neutral-400",children:"Jede Zeile wird ein eigener Stichpunkt (unter den Produkten). Text markieren und „Fett“ klicken, um ihn hervorzuheben."}),e.jsx("button",{type:"button",onClick:u,className:"mb-1 rounded-md border border-neutral-300 px-2 py-1 text-xs font-bold text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Fett"}),e.jsx("textarea",{ref:f,rows:5,value:r.form.description,onChange:c=>b({description:c.target.value}),onInput:Ce,className:A}),r.existing&&e.jsx(Pe,{children:e.jsx(Se,{fieldKey:`packages.${r.existing.id}.description`,previewText:"Beispieltext"})})]}),e.jsxs("div",{className:"grid gap-4 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Markierung"}),e.jsx("select",{value:r.form.badge,onChange:c=>b({badge:c.target.value}),className:A,children:Le.map(c=>e.jsx("option",{value:c.value,children:c.label},c.value))}),r.form.badge==="custom"&&e.jsx("input",{value:r.form.badge_text,onChange:c=>b({badge_text:c.target.value}),maxLength:40,placeholder:'z. B. "Neu" oder "Angebot"',className:`${A} mt-2`})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Video-Link (optional)"}),e.jsx("input",{type:"url",value:r.form.video_url,onChange:c=>b({video_url:c.target.value}),placeholder:"https://youtu.be/…",className:A}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Zeigt auf der Kachel „Zum Video“."})]})]}),e.jsxs("details",{className:"rounded-lg border border-neutral-200 dark:border-neutral-800",children:[e.jsx("summary",{className:"cursor-pointer select-none px-3 py-2 text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Weitere Optionen (Preis-Text, Sortierung)"}),e.jsxs("div",{className:"space-y-4 border-t border-neutral-200 p-3 dark:border-neutral-800",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Preis-Text (optional)"}),e.jsx("input",{value:r.form.price_text,onChange:c=>b({price_text:c.target.value}),placeholder:'z. B. "Coming soon" oder "Preis auf Anfrage"',className:A}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Ersetzt auf der Kachel den berechneten Preis, solange ausgefüllt."}),r.existing&&e.jsx(Pe,{children:e.jsx(Se,{fieldKey:`packages.${r.existing.id}.price_text`,previewText:"Beispieltext"})})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Sortierung"}),e.jsx("input",{type:"number",value:r.form.sort_order,onChange:c=>b({sort_order:c.target.value}),className:`${A} max-w-[160px]`})]})]})]}),e.jsxs("details",{className:"rounded-lg border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("summary",{className:"cursor-pointer select-none px-3 py-2 text-sm font-medium text-neutral-600 dark:text-neutral-300",children:["Englisch (optional)",(r.form.description_en||r.form.price_text_en)&&e.jsx("span",{className:"ml-2 text-xs text-brand-600",children:"● ausgefüllt"})]}),e.jsxs("div",{className:"space-y-4 border-t border-neutral-200 p-3 dark:border-neutral-800",children:[e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Für Besucher mit englischer Sprache. Leere Felder zeigen automatisch den deutschen Text."}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung (Englisch)"}),e.jsx("textarea",{rows:4,value:r.form.description_en,onChange:c=>b({description_en:c.target.value}),onInput:Ce,placeholder:r.form.description?"Leer = deutscher Text":"",className:A})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Preis-Text (Englisch)"}),e.jsx("input",{value:r.form.price_text_en,onChange:c=>b({price_text_en:c.target.value}),placeholder:'z. B. "Price on request"',className:A})]})]})]}),r.existing&&e.jsx("button",{type:"button",onClick:y,className:"text-sm text-red-600 hover:underline",children:"Paket löschen"}),l&&e.jsx("p",{className:"text-sm text-red-600",children:l})]}),e.jsxs("div",{className:"space-y-5",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Aufschlag"}),e.jsxs("div",{className:"mb-2 flex gap-2",children:[e.jsxs("select",{value:r.form.markup_type,onChange:c=>b({markup_type:c.target.value}),className:"w-44 shrink-0 rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"none",children:"Kein Aufschlag"}),e.jsx("option",{value:"fixed",children:"Fester Betrag (€)"}),e.jsx("option",{value:"percent",children:"Prozent (%)"})]}),e.jsx("input",{type:"number",step:"0.01",min:"0",disabled:r.form.markup_type==="none",value:r.form.markup_value,onChange:c=>b({markup_value:c.target.value}),className:`${A} disabled:opacity-50`})]}),e.jsx(Pt,{products:n,form:r.form})]}),r.existing?e.jsxs(e.Fragment,{children:[e.jsx(Ct,{packageId:r.existing.id,products:n,onChange:j}),e.jsx(Et,{packageId:r.existing.id,upgrades:x,onChange:V})]}):e.jsx("p",{className:"rounded-lg border border-dashed border-neutral-300 p-3 text-sm text-neutral-500 dark:border-neutral-700 dark:text-neutral-400",children:"Produkte und Upgrades lassen sich hinzufügen, sobald das Paket mit „Alle speichern“ angelegt ist."})]})]})]})}function Ft(){const[r,a]=at(),n=r.get("model")||"",x=Number(r.get("paket"))||null,[o,h]=p.useState([]),[l,k]=p.useState(!1),[f,_]=p.useState([]),[E,b]=p.useState(""),[u,g]=p.useState([]),[y,j]=p.useState(null),[V,B]=p.useState(()=>new Set),[z,i]=p.useState({modelId:null,products:{},upgrades:{}}),[v,N]=p.useState({}),[c,L]=p.useState(!1),[D,W]=p.useState(null),[T,P]=p.useState(""),[M,G]=p.useState(!0),[ue,me]=p.useState(!1),[ee,te]=p.useState(null),[K,xe]=p.useState("all"),[H,ae]=p.useState("all"),[he,pe]=p.useState(null),U=oe(),be=p.useRef(new Map),ge=p.useRef(n);ge.current=n;const J=async()=>{const[t,s]=await Promise.all([S.get("/packages"),S.get("/models")]);return h(t),_(s),k(!0),t};p.useEffect(()=>{J()},[]);const fe=async t=>{const s=await S.get(`/models/${t}/package-items`);ge.current===String(t)&&i({modelId:String(t),products:Ee(s.products),upgrades:Ee(s.upgrades)})},F=p.useMemo(()=>new Map(f.map(t=>[t.id,t])),[f]),ke=p.useMemo(()=>{const t=new Map;return f.forEach(s=>{t.has(s.brand_id)||t.set(s.brand_id,s.brand_name)}),Array.from(t,([s,m])=>({id:s,name:m})).sort((s,m)=>s.name.localeCompare(m.name))},[f]),Fe=p.useMemo(()=>f.filter(t=>!E||String(t.brand_id)===E).sort((t,s)=>t.name.localeCompare(s.name)),[f,E]),O=n?F.get(Number(n)):null,le=p.useMemo(()=>u.some(ne),[u]),re=()=>!le||confirm("Ungespeicherte Änderungen verwerfen?");p.useEffect(()=>{if(!l||n||!x)return;const t=o.find(s=>s.id===x);t&&a({model:String(t.car_model_id),paket:String(t.id)},{replace:!0})},[l,n,x,o,a]),p.useEffect(()=>{const t=F.get(Number(n));t&&b(String(t.brand_id))},[n,F]),p.useEffect(()=>{if(!n){g([]),j(null);return}if(!l||y===n)return;const t=Y(Number(n),o);g(t),j(n),N({}),W(null),P(""),te(null);const s=t.find(m=>{var d;return((d=m.existing)==null?void 0:d.id)===x});B(new Set(s?[s.key]:[])),i({modelId:null,products:{},upgrades:{}}),fe(n)},[n,l,y]),p.useEffect(()=>{!x||y!==n||requestAnimationFrame(()=>{var t;(t=document.getElementById(`paket-${x}`))==null||t.scrollIntoView({behavior:"smooth",block:"start"})})},[x,y,n]),lt(le,"packages");const Oe=t=>{t===n||!re()||a(t?{model:t}:{})},Ve=t=>{if(!re())return;b(t);const s=F.get(Number(n));s&&String(s.brand_id)!==t&&a({})},We=t=>B(s=>{const m=new Set(s);return m.has(t)?m.delete(t):m.add(t),m}),Ge=(t,s)=>{g(m=>m.map(d=>d.key===t?{...d,checked:s}:d)),B(m=>{const d=new Set(m);return s?d.add(t):d.delete(t),d})},je=(t,s)=>g(m=>m.map(d=>d.key===t?{...d,form:{...d.form,...s}}:d)),qe=t=>{const s=be.current.get(t);if(!s)return;const{selectionStart:m,selectionEnd:d,value:$}=s;if(m===d)return;const C=$.slice(m,d),R=C.startsWith("**")&&C.endsWith("**")&&C.length>=4?C.slice(2,-2):`**${C}**`,I=$.slice(0,m)+R+$.slice(d);je(t,{description:I}),requestAnimationFrame(()=>{s.focus();const w=m+R.length;s.setSelectionRange(w,w)})},ve=(t,s,m)=>i(d=>({...d,[t]:{...d[t],[s]:m}})),Ne=t=>({name:t.tierName??t.existing.name,car_model_id:Number(n),...t.form,markup_value:Number(t.form.markup_value),sort_order:Number(t.form.sort_order)}),Ze=async()=>{L(!0),W(null);const t={},s=u;let m=0,d=0;for(const w of u)try{w.existing?ne(w)&&(await S.put(`/packages/${w.existing.id}`,Ne(w)),d+=1):w.checked&&(await S.post("/packages",Ne(w)),m+=1)}catch(Q){t[w.key]=Q.message}const $=await J(),C=Y(Number(n),$).map(w=>{if(!t[w.key])return w;const Q=s.find(st=>st.key===w.key);return Q?{...w,checked:Q.checked,form:Q.form}:w});g(C),N(t);const q=Object.keys(t).length,R=[];m&&R.push(`${m} neu angelegt – Produkte können jetzt hinzugefügt werden`),d&&R.push(`${d} aktualisiert`),!R.length&&!q&&R.push("Keine Änderungen");const I=q?{kind:"error",text:`${R.join(", ")||"Nichts gespeichert"} – ${q} Paket(e) fehlgeschlagen (Details im Paket).`}:{kind:"ok",text:`${R.join(", ")}.`};W(I),q?U.error(I.text):U.success(I.text),L(!1)},He=async t=>{const s=t.tierName??t.existing.name;if(!confirm(`Paket "${s}" inkl. aller Produkte und Upgrades wirklich löschen?`))return;try{await S.delete(`/packages/${t.existing.id}`)}catch(d){U.error(`Löschen fehlgeschlagen: ${d.message}`);return}const m=await J();g(Y(Number(n),m)),W(null),U.success(`Paket „${s}“ gelöscht.`)},_e=async t=>{pe(t.id);try{const s=await S.patch(`/packages/${t.id}/visibility`,{is_hidden:!t.is_hidden}),m=d=>d.id===t.id?{...d,is_hidden:s.is_hidden}:d;h(d=>d.map(m)),g(d=>d.map($=>{var C;return((C=$.existing)==null?void 0:C.id)===t.id?{...$,existing:m($.existing)}:$})),U.success(s.is_hidden?`„${t.name}“ ist jetzt auf der Website ausgeblendet.`:`„${t.name}“ ist wieder sichtbar.`)}catch(s){U.error(`Sichtbarkeit konnte nicht geändert werden: ${s.message}`)}finally{pe(null)}},Je=async t=>{if(!confirm(`Paket "${t.name}" (${t.brand_name} ${t.model_name}) inkl. aller Produkte und Upgrades wirklich löschen?`))return;try{await S.delete(`/packages/${t.id}`)}catch(m){U.error(`Löschen fehlgeschlagen: ${m.message}`);return}const s=await J();n&&g(Y(Number(n),s)),U.success(`Paket „${t.name}“ gelöscht.`)},Qe=t=>{const s={model:String(t.car_model_id),paket:String(t.id)};if(String(t.car_model_id)===n){const m=u.find(d=>{var $;return(($=d.existing)==null?void 0:$.id)===t.id});m&&B(d=>new Set(d).add(m.key)),a(s,{replace:!0});return}re()&&a(s)},Ye=async()=>{if(!T||!re())return;const t=F.get(Number(T)),s=F.get(Number(n));if(confirm(`Alle Pakete von "${t.brand_name} ${t.name}" inkl. verknüpfter Produkte${M?" und Upgrades":""} nach "${s.brand_name} ${s.name}" kopieren? Bereits vorhandene Paketstufen werden übersprungen.`)){me(!0),te(null);try{const m=await S.post(`/models/${n}/copy-packages`,{source_model_id:Number(T),include_upgrades:M}),d=m.copied.reduce((R,I)=>R+I.products,0),$=m.copied.reduce((R,I)=>R+(I.upgrades||0),0),C=[`${m.copied.length} Paket(e) kopiert (${d} Produkte${M?`, ${$} Upgrades`:""})`];m.skipped.length&&C.push(`übersprungen: ${m.skipped.join(", ")}`),te({text:`${C.join(" – ")}.`}),U.success(`${C.join(" – ")}.`);const q=await J();g(Y(Number(n),q)),N({}),fe(n)}catch(m){te({error:m.message}),U.error(`Kopieren fehlgeschlagen: ${m.message}`)}me(!1)}},Xe=u.filter(t=>!t.existing&&t.checked).length,et=u.filter(t=>t.existing&&ne(t)).length,tt=u.filter(t=>t.existing||t.checked).map(t=>t.key),rt=z.modelId===n,nt=p.useMemo(()=>f.filter(t=>K==="all"||String(t.brand_id)===K).sort((t,s)=>t.name.localeCompare(s.name)),[f,K]),ie=p.useMemo(()=>o.filter(t=>{const s=F.get(t.car_model_id);return!(K!=="all"&&String(s==null?void 0:s.brand_id)!==K||H!=="all"&&String(t.car_model_id)!==H)}),[o,F,K,H]),ye=e.jsxs("div",{children:[e.jsxs("div",{className:"mb-3 flex flex-wrap items-center gap-2",children:[e.jsx("label",{className:"text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Filtern:"}),e.jsxs("select",{value:K,onChange:t=>{xe(t.target.value),ae("all")},className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"all",children:"Alle Marken"}),ke.map(t=>e.jsx("option",{value:String(t.id),children:t.name},t.id))]}),e.jsxs("select",{value:H,onChange:t=>ae(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"all",children:"Alle Modelle"}),nt.map(t=>e.jsxs("option",{value:String(t.id),children:[t.brand_name," ",t.name]},t.id))]}),(K!=="all"||H!=="all")&&e.jsx("button",{onClick:()=>{xe("all"),ae("all")},className:"text-sm text-brand-600 hover:underline",children:"Filter zurücksetzen"}),e.jsxs("span",{className:"text-sm text-neutral-400",children:[ie.length," von ",o.length]})]}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full min-w-[640px] text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Marke / Modell"}),e.jsx("th",{className:"px-4 py-2",children:"Paket"}),e.jsx("th",{className:"px-4 py-2",children:"Aufschlag"}),e.jsx("th",{className:"px-4 py-2",children:"Website"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[ie.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2",children:[t.brand_name," ",t.model_name]}),e.jsx("td",{className:"px-4 py-2 font-medium text-neutral-800 dark:text-neutral-100",children:e.jsxs("span",{className:`inline-flex flex-wrap items-center gap-1.5 ${t.is_hidden?"opacity-60":""}`,children:[t.name,e.jsx(De,{badge:t.badge,text:t.badge_text}),t.video_url&&e.jsx(Ae,{className:"h-4 w-4 text-red-500","aria-label":"Mit Video-Link"})]})}),e.jsxs("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:[t.markup_type==="fixed"&&`+${t.markup_value} €`,t.markup_type==="percent"&&`+${t.markup_value} %`,(!t.markup_type||t.markup_type==="none")&&"–"]}),e.jsx("td",{className:"px-4 py-2",children:e.jsx(Ke,{pkg:t,busy:he===t.id,onToggle:_e})}),e.jsxs("td",{className:"px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>{Qe(t),window.scrollTo({top:0,behavior:"smooth"})},className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>Je(t),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),ie.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:5,className:"px-4 py-6 text-center text-neutral-400",children:o.length===0?"Noch keine Pakete angelegt.":"Keine Pakete für diesen Filter."})})]})]})})]});return e.jsxs("div",{className:"space-y-6",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Pakete"}),e.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-3 font-bold text-neutral-900 dark:text-white",children:"Modell wählen"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsxs("select",{value:E,onChange:t=>Ve(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Marke wählen…"}),ke.map(t=>e.jsx("option",{value:String(t.id),children:t.name},t.id))]}),e.jsxs("select",{value:n,onChange:t=>Oe(t.target.value),className:"min-w-[220px] rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Modell wählen…"}),Fe.map(t=>e.jsxs("option",{value:String(t.id),children:[t.brand_name," ",t.name]},t.id))]})]}),!n&&e.jsx("p",{className:"mt-2 text-sm text-neutral-500 dark:text-neutral-400",children:"Modell auswählen, um dessen Pakete mit Produkten, Upgrades und Preisen zu bearbeiten – alles auf dieser Seite."})]}),O&&e.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsxs("div",{className:"border-b border-neutral-200 px-5 py-4 dark:border-neutral-800",children:[e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[e.jsxs("h2",{className:"flex flex-wrap items-center gap-3 font-bold text-neutral-900 dark:text-white",children:["Pakete für ",O.brand_name," ",O.name,O.brand_slug&&O.slug&&e.jsx(ct,{to:`/fahrzeuge/${O.brand_slug}/${O.slug}`,label:"Auf der Website ansehen"})]}),e.jsxs("div",{className:"flex gap-3 text-sm",children:[e.jsx("button",{type:"button",onClick:()=>B(new Set(tt)),className:"text-brand-600 hover:underline",children:"Alle aufklappen"}),e.jsx("button",{type:"button",onClick:()=>B(new Set),className:"text-brand-600 hover:underline",children:"Alle zuklappen"})]})]}),e.jsx("p",{className:"mt-1 text-sm text-neutral-500 dark:text-neutral-400",children:"Paket anklicken zum Bearbeiten. Produkte, Upgrades und Sichtbarkeit werden sofort gespeichert, Texte und Aufschläge mit „Alle speichern“ unten."}),e.jsxs("div",{className:"mt-3 flex flex-wrap items-center gap-2 rounded-lg border border-neutral-200 bg-neutral-50 px-3 py-2.5 dark:border-neutral-800 dark:bg-neutral-950",children:[e.jsx("span",{className:"text-sm font-medium text-neutral-600 dark:text-neutral-300",children:"Pakete von anderem Modell kopieren:"}),e.jsxs("select",{value:T,onChange:t=>P(t.target.value),className:"rounded-md border border-neutral-300 bg-white px-3 py-1.5 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:[e.jsx("option",{value:"",children:"Quellmodell wählen…"}),f.filter(t=>String(t.id)!==n).sort((t,s)=>`${t.brand_name} ${t.name}`.localeCompare(`${s.brand_name} ${s.name}`)).map(t=>e.jsxs("option",{value:String(t.id),children:[t.brand_name," ",t.name]},t.id))]}),e.jsxs("label",{className:"flex items-center gap-1.5 text-sm text-neutral-600 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:M,onChange:t=>G(t.target.checked),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"inkl. Upgrades"]}),e.jsx("button",{type:"button",onClick:Ye,disabled:!T||ue,className:"rounded-md border border-brand-500 px-3 py-1.5 text-sm font-semibold text-brand-600 hover:bg-brand-50 disabled:opacity-50 dark:hover:bg-brand-900/20",children:ue?"Kopiert…":"Kopieren"}),ee&&e.jsx("span",{className:`w-full text-sm ${ee.error?"text-red-600":"text-brand-600 dark:text-brand-400"}`,children:ee.error||ee.text})]})]}),u.map((t,s)=>{var m;return e.jsxs("div",{children:[t.tierName===null&&s>0&&u[s-1].tierName!==null&&e.jsx("div",{className:"border-t border-neutral-200 bg-neutral-50 px-5 py-2 text-xs font-semibold uppercase tracking-wide text-neutral-500 dark:border-neutral-800 dark:bg-neutral-950 dark:text-neutral-400",children:"Weitere Pakete (alte Namen)"}),e.jsx(Mt,{row:t,open:V.has(t.key),products:t.existing&&z.products[t.existing.id]||Re,upgrades:t.existing&&z.upgrades[t.existing.id]||Re,itemsLoaded:rt,saving:c,error:v[t.key],visibilityBusy:he===((m=t.existing)==null?void 0:m.id),descriptionRef:d=>be.current.set(t.key,d),onToggleOpen:()=>We(t.key),onToggleCreate:d=>Ge(t.key,d),onChangeForm:d=>je(t.key,d),onBold:()=>qe(t.key),onToggleVisibility:_e,onDelete:()=>He(t),onProductsChange:d=>ve("products",t.existing.id,d),onUpgradesChange:d=>ve("upgrades",t.existing.id,d)})]},t.key)}),e.jsxs("div",{className:"sticky bottom-0 z-10 flex flex-wrap items-center gap-3 rounded-b-xl border-t border-neutral-200 bg-white px-5 py-3 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("button",{type:"button",onClick:Ze,disabled:c||!le,className:"rounded-md bg-brand-500 px-5 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:c?"Speichert…":"Alle speichern"}),e.jsxs("span",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:[Xe," neu, ",et," geändert"]}),D&&e.jsx("span",{className:`text-sm ${D.kind==="error"?"text-red-600":"text-brand-600 dark:text-brand-400"}`,children:D.text})]})]}),O?e.jsxs("details",{className:"rounded-xl border border-neutral-200 bg-white dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("summary",{className:"cursor-pointer select-none px-5 py-3 font-bold text-neutral-900 dark:text-white",children:"Alle Pakete (Übersicht)"}),e.jsx("div",{className:"border-t border-neutral-200 p-5 dark:border-neutral-800",children:ye})]}):ye]})}export{Ft as default}; diff --git a/hifi/assets/Partners-Cm2S6bro.js b/hifi/assets/Partners-B5umAj33.js similarity index 93% rename from hifi/assets/Partners-Cm2S6bro.js rename to hifi/assets/Partners-B5umAj33.js index 239bd5c..1314f57 100644 --- a/hifi/assets/Partners-Cm2S6bro.js +++ b/hifi/assets/Partners-B5umAj33.js @@ -1 +1 @@ -import{o as P,r as n,p as R,j as e,c as h}from"./index-Tg8iNBwT.js";import{I as F}from"./ImageUploadField-Ds8_wHup.js";import{S as L,s as C}from"./SortableList-DRJ1jYgo.js";import{V as E}from"./ViewOnSite-CVVA03Ho.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";const u={name:"",logo_path:"",sort_order:0};function z(){const o=P(),[i,d]=n.useState([]),[a,c]=n.useState(u),[y,f]=n.useState(u),[s,j]=n.useState(null),[N,x]=n.useState(""),p=n.useRef(null);R(JSON.stringify(a)!==JSON.stringify(y),"partners");const g=()=>h.get("/partners").then(d);n.useEffect(()=>{g()},[]);const w=t=>{const r={name:t.name,logo_path:t.logo_path||"",sort_order:t.sort_order};j(t.id),c(r),f(r),x(""),requestAnimationFrame(()=>{var l,m,k;(l=p.current)==null||l.scrollIntoView({behavior:"smooth",block:"start"}),(k=(m=p.current)==null?void 0:m.querySelector("input"))==null||k.focus({preventScroll:!0})})},b=()=>{j(null),c(u),f(u)},v=async t=>{t.preventDefault(),x("");try{if(s)await h.put(`/partners/${s}`,a);else{const r=i.reduce((l,m)=>Math.max(l,Number(m.sort_order)||0),0)+10;await h.post("/partners",{...a,sort_order:r})}o.success(s?"Partner gespeichert.":"Partner angelegt."),b(),g()}catch(r){x(r.message)}},S=async t=>{if(confirm("Partner wirklich löschen?"))try{await h.delete(`/partners/${t}`),s===t&&b(),o.success("Partner gelöscht."),g()}catch(r){o.error(`Löschen fehlgeschlagen: ${r.message}`)}},_=async t=>{const r=i;d(t);try{d(await C("partners",t)),o.success("Reihenfolge gespeichert.")}catch(l){d(r),o.error(`Reihenfolge konnte nicht gespeichert werden: ${l.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex flex-wrap items-center justify-between gap-2",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Partner"}),e.jsx(E,{to:"/",label:"Startseite ansehen"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Die Marken-Logozeile auf der Startseite. Ohne Logo wird der Name als Text angezeigt. Reihenfolge am Griff links per Ziehen ändern."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Logo"}),e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(L,{items:i,onReorder:_,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.logo_path?e.jsx("img",{src:t.logo_path,alt:"",className:"h-10 w-10 rounded-md object-contain"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:t.name}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>w(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>S(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),i.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:4,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Partner angelegt."})})})]})})]}),e.jsxs("form",{ref:p,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:s?"Partner bearbeiten":"Neuer Partner"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:a.name,onChange:t=>c({...a,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(F,{value:a.logo_path,onChange:t=>c({...a,logo_path:t}),label:"Logo (optional)"}),N&&e.jsx("p",{className:"text-sm text-red-600",children:N}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:s?"Speichern":"Anlegen"}),s&&e.jsx("button",{type:"button",onClick:b,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{z as default}; +import{o as P,r as n,p as R,j as e,c as h}from"./index-Cc1wEeIX.js";import{I as F}from"./ImageUploadField-DYOhdPMm.js";import{S as L,s as C}from"./SortableList-DIXFCDYS.js";import{V as E}from"./ViewOnSite-CStAY6xT.js";import"./resizeImage-C6PvAwh0.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";const u={name:"",logo_path:"",sort_order:0};function z(){const o=P(),[i,d]=n.useState([]),[a,c]=n.useState(u),[y,f]=n.useState(u),[s,j]=n.useState(null),[N,x]=n.useState(""),p=n.useRef(null);R(JSON.stringify(a)!==JSON.stringify(y),"partners");const g=()=>h.get("/partners").then(d);n.useEffect(()=>{g()},[]);const w=t=>{const r={name:t.name,logo_path:t.logo_path||"",sort_order:t.sort_order};j(t.id),c(r),f(r),x(""),requestAnimationFrame(()=>{var l,m,k;(l=p.current)==null||l.scrollIntoView({behavior:"smooth",block:"start"}),(k=(m=p.current)==null?void 0:m.querySelector("input"))==null||k.focus({preventScroll:!0})})},b=()=>{j(null),c(u),f(u)},v=async t=>{t.preventDefault(),x("");try{if(s)await h.put(`/partners/${s}`,a);else{const r=i.reduce((l,m)=>Math.max(l,Number(m.sort_order)||0),0)+10;await h.post("/partners",{...a,sort_order:r})}o.success(s?"Partner gespeichert.":"Partner angelegt."),b(),g()}catch(r){x(r.message)}},S=async t=>{if(confirm("Partner wirklich löschen?"))try{await h.delete(`/partners/${t}`),s===t&&b(),o.success("Partner gelöscht."),g()}catch(r){o.error(`Löschen fehlgeschlagen: ${r.message}`)}},_=async t=>{const r=i;d(t);try{d(await C("partners",t)),o.success("Reihenfolge gespeichert.")}catch(l){d(r),o.error(`Reihenfolge konnte nicht gespeichert werden: ${l.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-4 flex flex-wrap items-center justify-between gap-2",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Partner"}),e.jsx(E,{to:"/",label:"Startseite ansehen"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Die Marken-Logozeile auf der Startseite. Ohne Logo wird der Name als Text angezeigt. Reihenfolge am Griff links per Ziehen ändern."}),e.jsx("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-8 px-2 py-2","aria-label":"Reihenfolge"}),e.jsx("th",{className:"px-4 py-2",children:"Logo"}),e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(L,{items:i,onReorder:_,as:"tbody",className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:(t,r)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"bg-white px-2 py-2 dark:bg-neutral-950",children:r}),e.jsx("td",{className:"bg-white px-4 py-2 dark:bg-neutral-950",children:t.logo_path?e.jsx("img",{src:t.logo_path,alt:"",className:"h-10 w-10 rounded-md object-contain"}):e.jsx("span",{className:"flex h-10 w-10 items-center justify-center rounded-md bg-neutral-100 text-xs text-neutral-400 dark:bg-neutral-800",children:"–"})}),e.jsx("td",{className:"bg-white px-4 py-2 font-medium text-neutral-800 dark:bg-neutral-950 dark:text-neutral-100",children:t.name}),e.jsxs("td",{className:"whitespace-nowrap bg-white px-4 py-2 text-right dark:bg-neutral-950",children:[e.jsx("button",{onClick:()=>w(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>S(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})}),i.length===0&&e.jsx("tbody",{children:e.jsx("tr",{children:e.jsx("td",{colSpan:4,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Partner angelegt."})})})]})})]}),e.jsxs("form",{ref:p,onSubmit:v,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:s?"Partner bearbeiten":"Neuer Partner"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:a.name,onChange:t=>c({...a,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(F,{value:a.logo_path,onChange:t=>c({...a,logo_path:t}),label:"Logo (optional)"}),N&&e.jsx("p",{className:"text-sm text-red-600",children:N}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:s?"Speichern":"Anlegen"}),s&&e.jsx("button",{type:"button",onClick:b,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{z as default}; diff --git a/hifi/assets/PermissionGroups-7L2JMWh8.js b/hifi/assets/PermissionGroups-C919vkqw.js similarity index 98% rename from hifi/assets/PermissionGroups-7L2JMWh8.js rename to hifi/assets/PermissionGroups-C919vkqw.js index ba00ba4..39f9d3c 100644 --- a/hifi/assets/PermissionGroups-7L2JMWh8.js +++ b/hifi/assets/PermissionGroups-C919vkqw.js @@ -1 +1 @@ -import{r as n,j as e,c as i}from"./index-Tg8iNBwT.js";const h={name:"",description:"",permissions:[]};function w(){const[c,b]=n.useState([]),[o,g]=n.useState([]),[r,a]=n.useState(h),[l,u]=n.useState(null),[m,x]=n.useState(""),d=()=>{i.get("/permission-groups").then(b),i.get("/permissions/catalog").then(g)};n.useEffect(d,[]);const j=t=>{u(t.id),a({name:t.name,description:t.description||"",permissions:t.permissions})},p=()=>{u(null),a(h)},N=t=>{a(s=>({...s,permissions:s.permissions.includes(t)?s.permissions.filter(y=>y!==t):[...s.permissions,t]}))},k=async t=>{t.preventDefault(),x("");try{l?await i.put(`/permission-groups/${l}`,r):await i.post("/permission-groups",r),p(),d()}catch(s){x(s.message)}},f=async t=>{confirm("Diese Berechtigungsgruppe wirklich löschen? Benutzer behalten ihre sonstigen Rechte.")&&(await i.delete(`/permission-groups/${t}`),d())};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Berechtigungsgruppen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Fasse mehrere Berechtigungen zu einer Gruppe zusammen (z. B. „Werkstatt"), die du dann bequem einem oder mehreren Benutzern zuweisen kannst.'}),e.jsx("div",{className:"overflow-hidden rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2",children:"Berechtigungen"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[c.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:t.name}),t.description&&e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]}),e.jsxs("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:[t.permissions.length," von ",o.length]}),e.jsxs("td",{className:"px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>j(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>f(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),c.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:3,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Berechtigungsgruppen angelegt."})})]})]})})]}),e.jsxs("form",{onSubmit:k,className:"h-fit space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:l?"Gruppe bearbeiten":"Neue Gruppe"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:r.name,onChange:t=>a({...r,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung"}),e.jsx("textarea",{rows:2,value:r.description,onChange:t=>a({...r,description:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Berechtigungen"}),e.jsx("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:o.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.permissions.includes(t.key),onChange:()=>N(t.key),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.label]},t.key))})]}),m&&e.jsx("p",{className:"text-sm text-red-600",children:m}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:l?"Speichern":"Anlegen"}),l&&e.jsx("button",{type:"button",onClick:p,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{w as default}; +import{r as n,j as e,c as i}from"./index-Cc1wEeIX.js";const h={name:"",description:"",permissions:[]};function w(){const[c,b]=n.useState([]),[o,g]=n.useState([]),[r,a]=n.useState(h),[l,u]=n.useState(null),[m,x]=n.useState(""),d=()=>{i.get("/permission-groups").then(b),i.get("/permissions/catalog").then(g)};n.useEffect(d,[]);const j=t=>{u(t.id),a({name:t.name,description:t.description||"",permissions:t.permissions})},p=()=>{u(null),a(h)},N=t=>{a(s=>({...s,permissions:s.permissions.includes(t)?s.permissions.filter(y=>y!==t):[...s.permissions,t]}))},k=async t=>{t.preventDefault(),x("");try{l?await i.put(`/permission-groups/${l}`,r):await i.post("/permission-groups",r),p(),d()}catch(s){x(s.message)}},f=async t=>{confirm("Diese Berechtigungsgruppe wirklich löschen? Benutzer behalten ihre sonstigen Rechte.")&&(await i.delete(`/permission-groups/${t}`),d())};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:"Berechtigungsgruppen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Fasse mehrere Berechtigungen zu einer Gruppe zusammen (z. B. „Werkstatt"), die du dann bequem einem oder mehreren Benutzern zuweisen kannst.'}),e.jsx("div",{className:"overflow-hidden rounded-xl border border-neutral-200 dark:border-neutral-800",children:e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-4 py-2",children:"Name"}),e.jsx("th",{className:"px-4 py-2",children:"Berechtigungen"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsxs("tbody",{className:"divide-y divide-neutral-100 dark:divide-neutral-800",children:[c.map(t=>e.jsxs("tr",{className:"bg-white dark:bg-neutral-950",children:[e.jsxs("td",{className:"px-4 py-2",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:t.name}),t.description&&e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]}),e.jsxs("td",{className:"px-4 py-2 text-neutral-500 dark:text-neutral-400",children:[t.permissions.length," von ",o.length]}),e.jsxs("td",{className:"px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>j(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>f(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]},t.id)),c.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:3,className:"px-4 py-6 text-center text-neutral-400",children:"Noch keine Berechtigungsgruppen angelegt."})})]})]})})]}),e.jsxs("form",{onSubmit:k,className:"h-fit space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:l?"Gruppe bearbeiten":"Neue Gruppe"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:r.name,onChange:t=>a({...r,name:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung"}),e.jsx("textarea",{rows:2,value:r.description,onChange:t=>a({...r,description:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1 text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Berechtigungen"}),e.jsx("div",{className:"space-y-1.5 rounded-md border border-neutral-200 p-3 dark:border-neutral-700",children:o.map(t=>e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.permissions.includes(t.key),onChange:()=>N(t.key),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),t.label]},t.key))})]}),m&&e.jsx("p",{className:"text-sm text-red-600",children:m}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:l?"Speichern":"Anlegen"}),l&&e.jsx("button",{type:"button",onClick:p,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{w as default}; diff --git a/hifi/assets/ResetSettings-BYj4e5tP.js b/hifi/assets/ResetSettings-Be0-Za-k.js similarity index 99% rename from hifi/assets/ResetSettings-BYj4e5tP.js rename to hifi/assets/ResetSettings-Be0-Za-k.js index 72e4835..1a9010e 100644 --- a/hifi/assets/ResetSettings-BYj4e5tP.js +++ b/hifi/assets/ResetSettings-Be0-Za-k.js @@ -1 +1 @@ -import{r,j as e,L as U,c as d,A as P}from"./index-Tg8iNBwT.js";const o="LÖSCHEN";async function L(){const s=await fetch(`${P}/settings/export`,{credentials:"include"});if(!s.ok)throw new Error("Sicherung konnte nicht erstellt werden – es wurde nichts gelöscht.");const l=await s.blob(),n=URL.createObjectURL(l),a=document.createElement("a");a.href=n,a.download=`hifiplanet-sicherung-${new Date().toISOString().slice(0,10)}.json`,document.body.appendChild(a),a.click(),a.remove(),setTimeout(()=>URL.revokeObjectURL(n),1e3)}function q(){const[s,l]=r.useState(!1),[n,a]=r.useState(""),[b,x]=r.useState(!1),[k,i]=r.useState(""),[p,f]=r.useState(!1),[y,u]=r.useState(""),[w,j]=r.useState(!1),[z,c]=r.useState(""),[S,N]=r.useState(!1),[F,m]=r.useState(""),[g,v]=r.useState(""),[h,C]=r.useState(""),B=async()=>{if(confirm("Alle aktuellen Leistungen werden gelöscht und durch die 8 Standard-Leistungen ersetzt. Fortfahren?")){l(!0),a("");try{const t=await d.post("/settings/reset-services",{});a(`${t.count} Standard-Leistungen wiederhergestellt.`)}catch(t){a("Fehler: "+t.message)}finally{l(!1)}}},A=async()=>{if(confirm("Alle aktuellen FAQ-Einträge werden gelöscht und durch die 6 Standard-Fragen ersetzt. Fortfahren?")){x(!0),i("");try{const t=await d.post("/settings/reset-faqs",{});i(`${t.count} Standard-Fragen wiederhergestellt.`)}catch(t){i("Fehler: "+t.message)}finally{x(!1)}}},R=async()=>{if(confirm("Die komplette Bildergalerie wird gelöscht und durch die 13 Marken/29 Projekte/207 Fotos der alten hifi-planet.de-Seite ersetzt. Fortfahren?")){f(!0),u("");try{const t=await d.post("/settings/reset-gallery",{});u(`${t.photos} Fotos wiederhergestellt.`)}catch(t){u("Fehler: "+t.message)}finally{f(!1)}}},E=async()=>{if(g.trim().toUpperCase()===o){j(!0),c("");try{await L();const t=await d.post("/settings/reset-catalog",{});v(""),c(`Fahrzeugkatalog geleert (${t.brands_removed} Marken entfernt).`)}catch(t){c("Fehler: "+t.message)}finally{j(!1)}}},$=async()=>{if(h.trim().toUpperCase()===o){N(!0),m("");try{await L();const t=await d.post("/settings/reset-all",{});C(""),m(`Erledigt: ${t.brands_removed} Marken entfernt, ${t.services_reset} Standard-Leistungen, ${t.faqs_reset} Standard-Fragen und ${t.gallery_photos_reset} Galerie-Fotos wiederhergestellt.`)}catch(t){m("Fehler: "+t.message)}finally{N(!1)}}};return e.jsxs("div",{className:"max-w-2xl space-y-6",children:[e.jsxs("p",{className:"rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:["Beim Leeren des Fahrzeugkatalogs und bei „Alles zurücksetzen“ wird vorher automatisch eine Sicherung heruntergeladen. Für die anderen Aktionen am besten vorher unter"," ",e.jsx(U,{to:"/admin/settings/export-import",className:"font-semibold underline",children:"Export & Import"})," sichern."]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur Leistungen zurücksetzen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle aktuellen Leistungen-Karten und stellt die 8 mitgelieferten Standard-Leistungen wieder her. Marken, Modelle und Pakete bleiben unangetastet."}),e.jsx("button",{onClick:B,disabled:s,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:s?"Setze zurück…":"Leistungen auf Standard zurücksetzen"}),n&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:n})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur FAQs zurücksetzen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle aktuellen Fragen und stellt die 6 mitgelieferten Standard-Fragen (Deutsch & Englisch) wieder her. Leistungen, Marken, Modelle und Pakete bleiben unangetastet."}),e.jsx("button",{onClick:A,disabled:b,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:b?"Setze zurück…":"FAQs auf Standard zurücksetzen"}),k&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:k})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur Bildergalerie zurücksetzen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle aktuellen Galerie-Marken, -Projekte und -Fotos und stellt die komplette Galerie der alten hifi-planet.de-Seite wieder her (13 Marken, 29 Projekte, 207 Fotos). Fahrzeugkatalog, Leistungen und FAQs bleiben unangetastet."}),e.jsx("button",{onClick:R,disabled:p,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:p?"Setze zurück…":"Galerie auf Standard zurücksetzen"}),y&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:y})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur Fahrzeugkatalog leeren"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle Marken, Modelle, Pakete, Produkte und Upgrades unwiderruflich. Leistungen, Kontaktanfragen und Benutzerkonten bleiben erhalten."}),e.jsx(M,{value:g,onChange:v}),e.jsx("button",{onClick:E,disabled:w||g.trim().toUpperCase()!==o,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:w?"Leere…":"Fahrzeugkatalog leeren"}),z&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:z})]}),e.jsxs("section",{className:"rounded-xl border border-red-300 bg-red-50/40 p-6 dark:border-red-900 dark:bg-red-900/10",children:[e.jsx("h2",{className:"mb-1 font-semibold text-red-700 dark:text-red-300",children:"Alles zurücksetzen"}),e.jsxs("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:["Kombiniert alles: Fahrzeugkatalog wird komplett geleert ",e.jsx("strong",{children:"und"})," Leistungen, FAQs sowie die Bildergalerie werden auf Standard zurückgesetzt. Kontaktanfragen und Benutzerkonten bleiben erhalten. Nicht rückgängig zu machen."]}),e.jsx(M,{value:h,onChange:C}),e.jsx("button",{onClick:$,disabled:S||h.trim().toUpperCase()!==o,className:"rounded-md bg-red-600 px-4 py-2 text-sm font-semibold text-white hover:bg-red-700 disabled:opacity-50",children:S?"Setze zurück…":"Wirklich alles zurücksetzen"}),F&&e.jsx("p",{className:"mt-3 text-sm text-neutral-700 dark:text-neutral-300",children:F})]})]})}function M({value:s,onChange:l}){return e.jsxs("label",{className:"mb-3 block text-sm text-neutral-600 dark:text-neutral-300",children:["Zur Bestätigung ",e.jsx("strong",{className:"font-mono",children:o})," eintippen:",e.jsx("input",{value:s,onChange:n=>l(n.target.value),autoComplete:"off",className:"mt-1 block w-48 rounded-md border border-red-300 bg-white px-3 py-2 font-mono text-sm dark:border-red-900 dark:bg-neutral-900"})]})}export{q as default}; +import{r,j as e,L as U,c as d,A as P}from"./index-Cc1wEeIX.js";const o="LÖSCHEN";async function L(){const s=await fetch(`${P}/settings/export`,{credentials:"include"});if(!s.ok)throw new Error("Sicherung konnte nicht erstellt werden – es wurde nichts gelöscht.");const l=await s.blob(),n=URL.createObjectURL(l),a=document.createElement("a");a.href=n,a.download=`hifiplanet-sicherung-${new Date().toISOString().slice(0,10)}.json`,document.body.appendChild(a),a.click(),a.remove(),setTimeout(()=>URL.revokeObjectURL(n),1e3)}function q(){const[s,l]=r.useState(!1),[n,a]=r.useState(""),[b,x]=r.useState(!1),[k,i]=r.useState(""),[p,f]=r.useState(!1),[y,u]=r.useState(""),[w,j]=r.useState(!1),[z,c]=r.useState(""),[S,N]=r.useState(!1),[F,m]=r.useState(""),[g,v]=r.useState(""),[h,C]=r.useState(""),B=async()=>{if(confirm("Alle aktuellen Leistungen werden gelöscht und durch die 8 Standard-Leistungen ersetzt. Fortfahren?")){l(!0),a("");try{const t=await d.post("/settings/reset-services",{});a(`${t.count} Standard-Leistungen wiederhergestellt.`)}catch(t){a("Fehler: "+t.message)}finally{l(!1)}}},A=async()=>{if(confirm("Alle aktuellen FAQ-Einträge werden gelöscht und durch die 6 Standard-Fragen ersetzt. Fortfahren?")){x(!0),i("");try{const t=await d.post("/settings/reset-faqs",{});i(`${t.count} Standard-Fragen wiederhergestellt.`)}catch(t){i("Fehler: "+t.message)}finally{x(!1)}}},R=async()=>{if(confirm("Die komplette Bildergalerie wird gelöscht und durch die 13 Marken/29 Projekte/207 Fotos der alten hifi-planet.de-Seite ersetzt. Fortfahren?")){f(!0),u("");try{const t=await d.post("/settings/reset-gallery",{});u(`${t.photos} Fotos wiederhergestellt.`)}catch(t){u("Fehler: "+t.message)}finally{f(!1)}}},E=async()=>{if(g.trim().toUpperCase()===o){j(!0),c("");try{await L();const t=await d.post("/settings/reset-catalog",{});v(""),c(`Fahrzeugkatalog geleert (${t.brands_removed} Marken entfernt).`)}catch(t){c("Fehler: "+t.message)}finally{j(!1)}}},$=async()=>{if(h.trim().toUpperCase()===o){N(!0),m("");try{await L();const t=await d.post("/settings/reset-all",{});C(""),m(`Erledigt: ${t.brands_removed} Marken entfernt, ${t.services_reset} Standard-Leistungen, ${t.faqs_reset} Standard-Fragen und ${t.gallery_photos_reset} Galerie-Fotos wiederhergestellt.`)}catch(t){m("Fehler: "+t.message)}finally{N(!1)}}};return e.jsxs("div",{className:"max-w-2xl space-y-6",children:[e.jsxs("p",{className:"rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:["Beim Leeren des Fahrzeugkatalogs und bei „Alles zurücksetzen“ wird vorher automatisch eine Sicherung heruntergeladen. Für die anderen Aktionen am besten vorher unter"," ",e.jsx(U,{to:"/admin/settings/export-import",className:"font-semibold underline",children:"Export & Import"})," sichern."]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur Leistungen zurücksetzen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle aktuellen Leistungen-Karten und stellt die 8 mitgelieferten Standard-Leistungen wieder her. Marken, Modelle und Pakete bleiben unangetastet."}),e.jsx("button",{onClick:B,disabled:s,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:s?"Setze zurück…":"Leistungen auf Standard zurücksetzen"}),n&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:n})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur FAQs zurücksetzen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle aktuellen Fragen und stellt die 6 mitgelieferten Standard-Fragen (Deutsch & Englisch) wieder her. Leistungen, Marken, Modelle und Pakete bleiben unangetastet."}),e.jsx("button",{onClick:A,disabled:b,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:b?"Setze zurück…":"FAQs auf Standard zurücksetzen"}),k&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:k})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur Bildergalerie zurücksetzen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle aktuellen Galerie-Marken, -Projekte und -Fotos und stellt die komplette Galerie der alten hifi-planet.de-Seite wieder her (13 Marken, 29 Projekte, 207 Fotos). Fahrzeugkatalog, Leistungen und FAQs bleiben unangetastet."}),e.jsx("button",{onClick:R,disabled:p,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:p?"Setze zurück…":"Galerie auf Standard zurücksetzen"}),y&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:y})]}),e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Nur Fahrzeugkatalog leeren"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Löscht alle Marken, Modelle, Pakete, Produkte und Upgrades unwiderruflich. Leistungen, Kontaktanfragen und Benutzerkonten bleiben erhalten."}),e.jsx(M,{value:g,onChange:v}),e.jsx("button",{onClick:E,disabled:w||g.trim().toUpperCase()!==o,className:"rounded-md border border-red-300 px-4 py-2 text-sm font-semibold text-red-600 hover:bg-red-50 disabled:opacity-50 dark:border-red-900 dark:hover:bg-red-900/20",children:w?"Leere…":"Fahrzeugkatalog leeren"}),z&&e.jsx("p",{className:"mt-3 text-sm text-neutral-600 dark:text-neutral-300",children:z})]}),e.jsxs("section",{className:"rounded-xl border border-red-300 bg-red-50/40 p-6 dark:border-red-900 dark:bg-red-900/10",children:[e.jsx("h2",{className:"mb-1 font-semibold text-red-700 dark:text-red-300",children:"Alles zurücksetzen"}),e.jsxs("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:["Kombiniert alles: Fahrzeugkatalog wird komplett geleert ",e.jsx("strong",{children:"und"})," Leistungen, FAQs sowie die Bildergalerie werden auf Standard zurückgesetzt. Kontaktanfragen und Benutzerkonten bleiben erhalten. Nicht rückgängig zu machen."]}),e.jsx(M,{value:h,onChange:C}),e.jsx("button",{onClick:$,disabled:S||h.trim().toUpperCase()!==o,className:"rounded-md bg-red-600 px-4 py-2 text-sm font-semibold text-white hover:bg-red-700 disabled:opacity-50",children:S?"Setze zurück…":"Wirklich alles zurücksetzen"}),F&&e.jsx("p",{className:"mt-3 text-sm text-neutral-700 dark:text-neutral-300",children:F})]})]})}function M({value:s,onChange:l}){return e.jsxs("label",{className:"mb-3 block text-sm text-neutral-600 dark:text-neutral-300",children:["Zur Bestätigung ",e.jsx("strong",{className:"font-mono",children:o})," eintippen:",e.jsx("input",{value:s,onChange:n=>l(n.target.value),autoComplete:"off",className:"mt-1 block w-48 rounded-md border border-red-300 bg-white px-3 py-2 font-mono text-sm dark:border-red-900 dark:bg-neutral-900"})]})}export{q as default}; diff --git a/hifi/assets/RichTextEditor-kI3KpNag.js b/hifi/assets/RichTextEditor-BGWsKoCk.js similarity index 99% rename from hifi/assets/RichTextEditor-kI3KpNag.js rename to hifi/assets/RichTextEditor-BGWsKoCk.js index c411552..7631ad6 100644 --- a/hifi/assets/RichTextEditor-kI3KpNag.js +++ b/hifi/assets/RichTextEditor-BGWsKoCk.js @@ -1,4 +1,4 @@ -import{r as q,v as xt,j as R,F as Gu,w as Yu}from"./index-Tg8iNBwT.js";var Hl={exports:{}},jl={};/** +import{r as q,v as xt,j as R,F as Gu,w as Yu}from"./index-Cc1wEeIX.js";var Hl={exports:{}},jl={};/** * @license React * use-sync-external-store-shim.production.js * diff --git a/hifi/assets/SaveBar-BdqoV5a_.js b/hifi/assets/SaveBar-Cr-Ys8TW.js similarity index 93% rename from hifi/assets/SaveBar-BdqoV5a_.js rename to hifi/assets/SaveBar-Cr-Ys8TW.js index ee486d3..9d12875 100644 --- a/hifi/assets/SaveBar-BdqoV5a_.js +++ b/hifi/assets/SaveBar-Cr-Ys8TW.js @@ -1 +1 @@ -import{j as e}from"./index-Tg8iNBwT.js";function m({dirty:t,busy:i,savedAt:a,onSave:n,label:s="Speichern",form:r}){return e.jsx("div",{className:"sticky bottom-0 z-20 -mx-4 mt-6 border-t border-neutral-200 bg-white/95 px-4 py-3 backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:-mx-6 sm:px-6",children:e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsx("p",{className:`text-sm ${t?"font-medium text-amber-600 dark:text-amber-400":"text-neutral-500 dark:text-neutral-400"}`,children:t?"● Ungespeicherte Änderungen":a?`✓ Gespeichert um ${a.toLocaleTimeString("de-DE",{hour:"2-digit",minute:"2-digit"})} Uhr`:"Alles gespeichert"}),e.jsx("button",{type:r?"submit":"button",form:r,onClick:r?void 0:n,disabled:i||!t,className:"rounded-md bg-brand-500 px-5 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":s})]})})}export{m as S}; +import{j as e}from"./index-Cc1wEeIX.js";function m({dirty:t,busy:i,savedAt:a,onSave:n,label:s="Speichern",form:r}){return e.jsx("div",{className:"sticky bottom-0 z-20 -mx-4 mt-6 border-t border-neutral-200 bg-white/95 px-4 py-3 backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:-mx-6 sm:px-6",children:e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsx("p",{className:`text-sm ${t?"font-medium text-amber-600 dark:text-amber-400":"text-neutral-500 dark:text-neutral-400"}`,children:t?"● Ungespeicherte Änderungen":a?`✓ Gespeichert um ${a.toLocaleTimeString("de-DE",{hour:"2-digit",minute:"2-digit"})} Uhr`:"Alles gespeichert"}),e.jsx("button",{type:r?"submit":"button",form:r,onClick:r?void 0:n,disabled:i||!t,className:"rounded-md bg-brand-500 px-5 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:i?"Speichere…":s})]})})}export{m as S}; diff --git a/hifi/assets/Services-CAauKrT-.js b/hifi/assets/Services-BuFoA76N.js similarity index 95% rename from hifi/assets/Services-CAauKrT-.js rename to hifi/assets/Services-BuFoA76N.js index 0977b8e..0b213d9 100644 --- a/hifi/assets/Services-CAauKrT-.js +++ b/hifi/assets/Services-BuFoA76N.js @@ -1 +1 @@ -import{r as i,j as e,o as R,p as F,D as T,c as h}from"./index-Tg8iNBwT.js";import{S as z,s as D}from"./SortableList-DRJ1jYgo.js";import{V as A}from"./ViewOnSite-CVVA03Ho.js";import{I as M}from"./ImageUploadField-Ds8_wHup.js";import{toComponentName as w,ICON_NAMES as b,findIcon as $}from"./iconRegistry-CE8benTi.js";import"./sortable.esm-DhUbHeHx.js";import"./grip-vertical-By7l82Pv.js";import"./resizeImage-C6PvAwh0.js";import"./music-DPTNgOWL.js";import"./eye-Bf2CUjOF.js";import"./trash-2-CnvKO1vQ.js";function y({name:l,className:c}){const r=$(l);return r?e.jsx(r,{className:c}):null}const O=120,V=200;function q({value:l,onChange:c}){const[r,a]=i.useState(""),d=l?w(l):null,u=i.useMemo(()=>{const s=r.trim().toLowerCase();return s?b.filter(x=>x.includes(s)).slice(0,V):b.slice(0,O)},[r]);return e.jsxs("div",{children:[e.jsxs("div",{className:"mb-2 flex items-center gap-3 rounded-md border border-neutral-300 p-2 dark:border-neutral-700",children:[e.jsx("div",{className:"flex h-10 w-10 shrink-0 items-center justify-center rounded-md bg-brand-100 text-brand-600 dark:bg-brand-900/40 dark:text-brand-400",children:l?e.jsx(y,{name:l,className:"h-6 w-6"}):e.jsx("span",{className:"text-xs text-neutral-400",children:"?"})}),e.jsxs("div",{className:"text-sm",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:l||"Kein Icon gewählt"}),e.jsxs("p",{className:"text-xs text-neutral-400",children:[b.length," Icons verfügbar"]})]})]}),e.jsx("input",{value:r,onChange:s=>a(s.target.value),placeholder:"Icon suchen (z. B. car, shield, zap)…",className:"mb-2 w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsxs("div",{className:"grid max-h-64 grid-cols-6 gap-1 overflow-y-auto rounded-md border border-neutral-200 p-2 sm:grid-cols-8 dark:border-neutral-700",children:[u.map(s=>e.jsx("button",{type:"button",title:s,onClick:()=>c(s),className:`flex h-10 w-10 items-center justify-center rounded-md transition ${d===w(s)?"bg-brand-500 text-white":"text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:e.jsx(y,{name:s,className:"h-5 w-5"})},s)),u.length===0&&e.jsx("p",{className:"col-span-full py-4 text-center text-sm text-neutral-400",children:"Keine Icons gefunden."})]}),!r&&e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:["Tipp: Tippe einen Suchbegriff ein, um alle ",b.length," Icons zu durchsuchen."]})]})}const p={icon_name:"",title:"",description:"",image_path:"",cta_label:"",cta_url:"",sort_order:0,title_en:"",description_en:"",cta_label_en:""},k="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900";function ee(){const[l,c]=i.useState([]),[r,a]=i.useState(p),[d,u]=i.useState(null),[s,x]=i.useState(""),[S,v]=i.useState(p),[g,f]=i.useState(!1),_=i.useRef(null),m=R();F(JSON.stringify(r)!==JSON.stringify(S),"services");const j=()=>h.get("/services").then(c);i.useEffect(j,[]);const I=t=>{var o;const n={icon_name:t.icon_name,title:t.title,description:t.description,image_path:t.image_path||"",cta_label:t.cta_label||"",cta_url:t.cta_url||"",sort_order:t.sort_order,title_en:t.title_en||"",description_en:t.description_en||"",cta_label_en:t.cta_label_en||""};u(t.id),a(n),v(n),f(!!(n.title_en||n.description_en||n.cta_label_en)),(o=_.current)==null||o.scrollIntoView({behavior:"smooth",block:"start"})},N=()=>{u(null),a(p),v(p),f(!1)},C=async t=>{if(t.preventDefault(),x(""),!r.icon_name){x("Bitte ein Icon auswählen");return}const n={...r,sort_order:Number(r.sort_order)};try{d?await h.put(`/services/${d}`,n):(n.sort_order=l.reduce((o,B)=>Math.max(o,Number(B.sort_order)||0),0)+10,await h.post("/services",n)),m.success(d?"Leistung gespeichert.":"Leistung angelegt."),N(),j()}catch(o){x(o.message)}},E=async t=>{if(confirm("Diese Leistung wirklich löschen?"))try{await h.delete(`/services/${t}`),d===t&&N(),m.success("Leistung gelöscht."),j()}catch(n){m.error(`Löschen fehlgeschlagen: ${n.message}`)}},L=async t=>{const n=l;c(t);try{c(await D("services",t)),m.success("Reihenfolge gespeichert.")}catch(o){c(n),m.error(`Reihenfolge konnte nicht gespeichert werden: ${o.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Leistungen"}),e.jsx(A,{to:"/leistungen"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Diese Karten erscheinen auf der öffentlichen Leistungen-Seite. Die 8 mitgelieferten Einträge sind die Standard-Einstellung – du kannst sie bearbeiten, löschen und beliebig neue hinzufügen. Reihenfolge am Griff links per Ziehen ändern."}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Icon"}),e.jsx("th",{className:"px-4 py-2",children:"Titel"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(z,{items:l,onReorder:L,as:"tbody",className:"divide-y divide-neutral-100 bg-white dark:divide-neutral-800 dark:bg-neutral-950",children:(t,n)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"px-2 py-2",children:n}),e.jsx("td",{className:"px-4 py-2",children:e.jsx("div",{className:"flex h-9 w-9 items-center justify-center rounded-full bg-brand-100 text-brand-600 dark:bg-brand-900/40 dark:text-brand-400",children:e.jsx(T,{name:t.icon_name,className:"h-5 w-5"})})}),e.jsx("td",{className:"px-4 py-2 font-medium text-neutral-800 dark:text-neutral-100",children:t.title}),e.jsxs("td",{className:"whitespace-nowrap px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>I(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>E(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),l.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:"Noch keine Leistungen angelegt."})]})]}),e.jsxs("form",{ref:_,onSubmit:C,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:d?"Leistung bearbeiten":"Neue Leistung"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Icon *"}),e.jsx(q,{value:r.icon_name,onChange:t=>a({...r,icon_name:t})})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:r.title,onChange:t=>a({...r,title:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung *"}),e.jsx("textarea",{required:!0,rows:4,value:r.description,onChange:t=>a({...r,description:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(M,{value:r.image_path,onChange:t=>a({...r,image_path:t}),aspect:4/3,label:"Bild"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Text (optional)"}),e.jsx("input",{value:r.cta_label,onChange:t=>a({...r,cta_label:t.target.value}),placeholder:"z. B. Fahrzeug konfigurieren",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Link (optional)"}),e.jsx("input",{value:r.cta_url,onChange:t=>a({...r,cta_url:t.target.value}),placeholder:"z. B. /fahrzeuge",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"rounded-lg border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("button",{type:"button",onClick:()=>f(t=>!t),"aria-expanded":g,className:"flex w-full items-center justify-between px-3 py-2 text-left text-sm font-medium text-neutral-700 dark:text-neutral-300",children:[e.jsx("span",{children:"Englische Version (optional)"}),e.jsx("span",{className:"text-neutral-400",children:g?"▲":"▼"})]}),g&&e.jsxs("div",{className:"space-y-3 border-t border-neutral-200 p-3 dark:border-neutral-800",children:[e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Leere Felder: Englische Besucher sehen den deutschen Text."}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name (Englisch)"}),e.jsx("input",{value:r.title_en,onChange:t=>a({...r,title_en:t.target.value}),placeholder:r.title,className:k})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung (Englisch)"}),e.jsx("textarea",{rows:4,value:r.description_en,onChange:t=>a({...r,description_en:t.target.value}),className:k})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Text (Englisch)"}),e.jsx("input",{value:r.cta_label_en,onChange:t=>a({...r,cta_label_en:t.target.value}),placeholder:r.cta_label,className:k})]})]})]}),s&&e.jsx("p",{className:"text-sm text-red-600",children:s}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:d?"Speichern":"Anlegen"}),d&&e.jsx("button",{type:"button",onClick:N,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{ee as default}; +import{r as i,j as e,o as R,p as F,D as T,c as h}from"./index-Cc1wEeIX.js";import{S as z,s as D}from"./SortableList-DIXFCDYS.js";import{V as A}from"./ViewOnSite-CStAY6xT.js";import{I as M}from"./ImageUploadField-DYOhdPMm.js";import{toComponentName as w,ICON_NAMES as b,findIcon as $}from"./iconRegistry-DrgKxhYw.js";import"./sortable.esm-D8IvDAze.js";import"./grip-vertical-0BUKE4NU.js";import"./resizeImage-C6PvAwh0.js";import"./music-B3GiJs_4.js";import"./eye-BXFieSB3.js";import"./trash-2-UGYx0Sek.js";function y({name:l,className:c}){const r=$(l);return r?e.jsx(r,{className:c}):null}const O=120,V=200;function q({value:l,onChange:c}){const[r,a]=i.useState(""),d=l?w(l):null,u=i.useMemo(()=>{const s=r.trim().toLowerCase();return s?b.filter(x=>x.includes(s)).slice(0,V):b.slice(0,O)},[r]);return e.jsxs("div",{children:[e.jsxs("div",{className:"mb-2 flex items-center gap-3 rounded-md border border-neutral-300 p-2 dark:border-neutral-700",children:[e.jsx("div",{className:"flex h-10 w-10 shrink-0 items-center justify-center rounded-md bg-brand-100 text-brand-600 dark:bg-brand-900/40 dark:text-brand-400",children:l?e.jsx(y,{name:l,className:"h-6 w-6"}):e.jsx("span",{className:"text-xs text-neutral-400",children:"?"})}),e.jsxs("div",{className:"text-sm",children:[e.jsx("p",{className:"font-medium text-neutral-800 dark:text-neutral-100",children:l||"Kein Icon gewählt"}),e.jsxs("p",{className:"text-xs text-neutral-400",children:[b.length," Icons verfügbar"]})]})]}),e.jsx("input",{value:r,onChange:s=>a(s.target.value),placeholder:"Icon suchen (z. B. car, shield, zap)…",className:"mb-2 w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsxs("div",{className:"grid max-h-64 grid-cols-6 gap-1 overflow-y-auto rounded-md border border-neutral-200 p-2 sm:grid-cols-8 dark:border-neutral-700",children:[u.map(s=>e.jsx("button",{type:"button",title:s,onClick:()=>c(s),className:`flex h-10 w-10 items-center justify-center rounded-md transition ${d===w(s)?"bg-brand-500 text-white":"text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:e.jsx(y,{name:s,className:"h-5 w-5"})},s)),u.length===0&&e.jsx("p",{className:"col-span-full py-4 text-center text-sm text-neutral-400",children:"Keine Icons gefunden."})]}),!r&&e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:["Tipp: Tippe einen Suchbegriff ein, um alle ",b.length," Icons zu durchsuchen."]})]})}const p={icon_name:"",title:"",description:"",image_path:"",cta_label:"",cta_url:"",sort_order:0,title_en:"",description_en:"",cta_label_en:""},k="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900";function ee(){const[l,c]=i.useState([]),[r,a]=i.useState(p),[d,u]=i.useState(null),[s,x]=i.useState(""),[S,v]=i.useState(p),[g,f]=i.useState(!1),_=i.useRef(null),m=R();F(JSON.stringify(r)!==JSON.stringify(S),"services");const j=()=>h.get("/services").then(c);i.useEffect(j,[]);const I=t=>{var o;const n={icon_name:t.icon_name,title:t.title,description:t.description,image_path:t.image_path||"",cta_label:t.cta_label||"",cta_url:t.cta_url||"",sort_order:t.sort_order,title_en:t.title_en||"",description_en:t.description_en||"",cta_label_en:t.cta_label_en||""};u(t.id),a(n),v(n),f(!!(n.title_en||n.description_en||n.cta_label_en)),(o=_.current)==null||o.scrollIntoView({behavior:"smooth",block:"start"})},N=()=>{u(null),a(p),v(p),f(!1)},C=async t=>{if(t.preventDefault(),x(""),!r.icon_name){x("Bitte ein Icon auswählen");return}const n={...r,sort_order:Number(r.sort_order)};try{d?await h.put(`/services/${d}`,n):(n.sort_order=l.reduce((o,B)=>Math.max(o,Number(B.sort_order)||0),0)+10,await h.post("/services",n)),m.success(d?"Leistung gespeichert.":"Leistung angelegt."),N(),j()}catch(o){x(o.message)}},E=async t=>{if(confirm("Diese Leistung wirklich löschen?"))try{await h.delete(`/services/${t}`),d===t&&N(),m.success("Leistung gelöscht."),j()}catch(n){m.error(`Löschen fehlgeschlagen: ${n.message}`)}},L=async t=>{const n=l;c(t);try{c(await D("services",t)),m.success("Reihenfolge gespeichert.")}catch(o){c(n),m.error(`Reihenfolge konnte nicht gespeichert werden: ${o.message}`)}};return e.jsxs("div",{className:"grid gap-6 lg:grid-cols-3",children:[e.jsxs("div",{className:"lg:col-span-2",children:[e.jsxs("div",{className:"mb-1 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-xl font-bold text-neutral-900 dark:text-white",children:"Leistungen"}),e.jsx(A,{to:"/leistungen"})]}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Diese Karten erscheinen auf der öffentlichen Leistungen-Seite. Die 8 mitgelieferten Einträge sind die Standard-Einstellung – du kannst sie bearbeiten, löschen und beliebig neue hinzufügen. Reihenfolge am Griff links per Ziehen ändern."}),e.jsxs("div",{className:"overflow-x-auto rounded-xl border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("table",{className:"w-full text-left text-sm",children:[e.jsx("thead",{className:"bg-neutral-50 text-neutral-500 dark:bg-neutral-900 dark:text-neutral-400",children:e.jsxs("tr",{children:[e.jsx("th",{className:"w-10 px-2 py-2",children:e.jsx("span",{className:"sr-only",children:"Reihenfolge"})}),e.jsx("th",{className:"px-4 py-2",children:"Icon"}),e.jsx("th",{className:"px-4 py-2",children:"Titel"}),e.jsx("th",{className:"px-4 py-2 text-right",children:"Aktionen"})]})}),e.jsx(z,{items:l,onReorder:L,as:"tbody",className:"divide-y divide-neutral-100 bg-white dark:divide-neutral-800 dark:bg-neutral-950",children:(t,n)=>e.jsxs(e.Fragment,{children:[e.jsx("td",{className:"px-2 py-2",children:n}),e.jsx("td",{className:"px-4 py-2",children:e.jsx("div",{className:"flex h-9 w-9 items-center justify-center rounded-full bg-brand-100 text-brand-600 dark:bg-brand-900/40 dark:text-brand-400",children:e.jsx(T,{name:t.icon_name,className:"h-5 w-5"})})}),e.jsx("td",{className:"px-4 py-2 font-medium text-neutral-800 dark:text-neutral-100",children:t.title}),e.jsxs("td",{className:"whitespace-nowrap px-4 py-2 text-right",children:[e.jsx("button",{onClick:()=>I(t),className:"mr-3 text-brand-600 hover:underline",children:"Bearbeiten"}),e.jsx("button",{onClick:()=>E(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]})]})})]}),l.length===0&&e.jsx("p",{className:"px-4 py-6 text-center text-sm text-neutral-400",children:"Noch keine Leistungen angelegt."})]})]}),e.jsxs("form",{ref:_,onSubmit:C,className:"h-fit scroll-mt-20 space-y-4 rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"font-bold text-neutral-900 dark:text-white",children:d?"Leistung bearbeiten":"Neue Leistung"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Icon *"}),e.jsx(q,{value:r.icon_name,onChange:t=>a({...r,icon_name:t})})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name *"}),e.jsx("input",{required:!0,value:r.title,onChange:t=>a({...r,title:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung *"}),e.jsx("textarea",{required:!0,rows:4,value:r.description,onChange:t=>a({...r,description:t.target.value}),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx(M,{value:r.image_path,onChange:t=>a({...r,image_path:t}),aspect:4/3,label:"Bild"}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Text (optional)"}),e.jsx("input",{value:r.cta_label,onChange:t=>a({...r,cta_label:t.target.value}),placeholder:"z. B. Fahrzeug konfigurieren",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Link (optional)"}),e.jsx("input",{value:r.cta_url,onChange:t=>a({...r,cta_url:t.target.value}),placeholder:"z. B. /fahrzeuge",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"rounded-lg border border-neutral-200 dark:border-neutral-800",children:[e.jsxs("button",{type:"button",onClick:()=>f(t=>!t),"aria-expanded":g,className:"flex w-full items-center justify-between px-3 py-2 text-left text-sm font-medium text-neutral-700 dark:text-neutral-300",children:[e.jsx("span",{children:"Englische Version (optional)"}),e.jsx("span",{className:"text-neutral-400",children:g?"▲":"▼"})]}),g&&e.jsxs("div",{className:"space-y-3 border-t border-neutral-200 p-3 dark:border-neutral-800",children:[e.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:"Leere Felder: Englische Besucher sehen den deutschen Text."}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name (Englisch)"}),e.jsx("input",{value:r.title_en,onChange:t=>a({...r,title_en:t.target.value}),placeholder:r.title,className:k})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Beschreibung (Englisch)"}),e.jsx("textarea",{rows:4,value:r.description_en,onChange:t=>a({...r,description_en:t.target.value}),className:k})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Button-Text (Englisch)"}),e.jsx("input",{value:r.cta_label_en,onChange:t=>a({...r,cta_label_en:t.target.value}),placeholder:r.cta_label,className:k})]})]})]}),s&&e.jsx("p",{className:"text-sm text-red-600",children:s}),e.jsxs("div",{className:"flex gap-2",children:[e.jsx("button",{type:"submit",className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:d?"Speichern":"Anlegen"}),d&&e.jsx("button",{type:"button",onClick:N,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Abbrechen"})]})]})]})}export{ee as default}; diff --git a/hifi/assets/SettingsLayout-CRAynHUX.js b/hifi/assets/SettingsLayout-Cbd5Mqx8.js similarity index 95% rename from hifi/assets/SettingsLayout-CRAynHUX.js rename to hifi/assets/SettingsLayout-Cbd5Mqx8.js index 901ac00..daa51d7 100644 --- a/hifi/assets/SettingsLayout-CRAynHUX.js +++ b/hifi/assets/SettingsLayout-Cbd5Mqx8.js @@ -1 +1 @@ -import{x as a,j as e,r as i,O as u}from"./index-Tg8iNBwT.js";const d={company:["Firmendaten","Telefon, Adresse, Öffnungszeiten, Logo und der Hinweis unter den Paketpreisen."],design:["Aussehen","Titelbild, Schriften und das Aussehen der Kacheln auf der Website."],legal:["Rechtstexte","Impressum, Datenschutzerklärung und AGB."],maintenance:["Wartungsmodus","Die ganze Website oder einzelne Bereiche vorübergehend für Besucher sperren."],email:["E-Mail-Versand","Zugangsdaten des Mail-Servers und die Texte der automatischen E-Mails."],google:["Google-Dienste","Google Analytics und Google-Bewertungen anbinden. Nur für Techniker."],database:["Datenbank","Verbindung und Struktur der Datenbank. Nur für Techniker."],"export-import":["Export & Import","Sicherung herunterladen oder auf einem anderen Server einspielen."],update:["Updates","Neue Versionen der Website installieren."],reset:["Zurücksetzen","Inhalte auf den Auslieferungszustand zurücksetzen. Vorher unbedingt exportieren."]};function o(){const{pathname:t}=a(),r=t.replace(/\/$/,"").split("/").pop(),[s,n]=d[r]||["Einstellungen",""];return e.jsxs("div",{children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:s}),n&&e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:n}),e.jsx(i.Suspense,{fallback:e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),children:e.jsx(u,{})})]})}export{o as default}; +import{x as a,j as e,r as i,O as u}from"./index-Cc1wEeIX.js";const d={company:["Firmendaten","Telefon, Adresse, Öffnungszeiten, Logo und der Hinweis unter den Paketpreisen."],design:["Aussehen","Titelbild, Schriften und das Aussehen der Kacheln auf der Website."],legal:["Rechtstexte","Impressum, Datenschutzerklärung und AGB."],maintenance:["Wartungsmodus","Die ganze Website oder einzelne Bereiche vorübergehend für Besucher sperren."],email:["E-Mail-Versand","Zugangsdaten des Mail-Servers und die Texte der automatischen E-Mails."],google:["Google-Dienste","Google Analytics und Google-Bewertungen anbinden. Nur für Techniker."],database:["Datenbank","Verbindung und Struktur der Datenbank. Nur für Techniker."],"export-import":["Export & Import","Sicherung herunterladen oder auf einem anderen Server einspielen."],update:["Updates","Neue Versionen der Website installieren."],reset:["Zurücksetzen","Inhalte auf den Auslieferungszustand zurücksetzen. Vorher unbedingt exportieren."]};function o(){const{pathname:t}=a(),r=t.replace(/\/$/,"").split("/").pop(),[s,n]=d[r]||["Einstellungen",""];return e.jsxs("div",{children:[e.jsx("h1",{className:"mb-1 text-xl font-bold text-neutral-900 dark:text-white",children:s}),n&&e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:n}),e.jsx(i.Suspense,{fallback:e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),children:e.jsx(u,{})})]})}export{o as default}; diff --git a/hifi/assets/SetupWizard-DYZvf-vp.js b/hifi/assets/SetupWizard-BH4s6ZYO.js similarity index 98% rename from hifi/assets/SetupWizard-DYZvf-vp.js rename to hifi/assets/SetupWizard-BH4s6ZYO.js index ee92da4..a934d73 100644 --- a/hifi/assets/SetupWizard-DYZvf-vp.js +++ b/hifi/assets/SetupWizard-BH4s6ZYO.js @@ -1 +1 @@ -import{b as E,r as x,c as b,j as e,l as P,L as k}from"./index-Tg8iNBwT.js";const F={host:"",name:"",user:"",password:"",charset:"utf8mb4"},L={username:"",password:"",password_confirmation:""};function z(){E({title:"Ersteinrichtung",path:"/setup"});const[n,c]=x.useState("loading"),[m,r]=x.useState(""),[u,o]=x.useState(!1),[f,v]=x.useState(""),[a,h]=x.useState(F),[l,p]=x.useState(L),[w,y]=x.useState(null),N=()=>b.get("/setup/status").then(t=>(t.needs_setup?t.steps.admin.ok?c("done"):t.steps.schema.ok?c("admin"):c(t.steps.database.ok?"schema":"database"):c("locked"),t));x.useEffect(()=>{b.get("/setup/status").then(t=>c(t.needs_setup?"password":"locked")).catch(()=>c("locked"))},[]);const D=async t=>{t.preventDefault(),r(""),o(!0);try{await b.post("/setup/verify-password",{password:f}),await N()}catch(s){r(s.message)}finally{o(!1)}},S=async t=>{t.preventDefault(),r(""),o(!0);try{await b.post("/setup/database",a),await N()}catch(s){r(s.message)}finally{o(!1)}},A=async()=>{r(""),o(!0);try{const t=await b.post("/setup/migrate",{});y(t.actions),t.status.steps.schema.ok&&c("admin")}catch(t){r(t.message)}finally{o(!1)}},C=async t=>{if(t.preventDefault(),r(""),l.password!==l.password_confirmation){r("Die Passwörter stimmen nicht überein");return}o(!0);try{await b.post("/setup/admin",l),c("done")}catch(s){r(s.message)}finally{o(!1)}},d="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900",i="mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",g=[{key:"database",label:"Datenbank"},{key:"schema",label:"Struktur"},{key:"admin",label:"Admin-Account"}],j=g.findIndex(t=>t.key===n);return e.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center gap-6 bg-neutral-50 px-4 py-12 dark:bg-neutral-950",children:[e.jsx("img",{src:P,alt:"HifiPlanet",className:"h-16 w-auto sm:h-20"}),e.jsxs("div",{className:"w-full max-w-md rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[n==="loading"&&e.jsx("p",{className:"text-center text-sm text-neutral-400",children:"Lädt…"}),n==="locked"&&e.jsxs("div",{className:"text-center",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Bereits eingerichtet"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Diese Seite wurde bereits vollständig eingerichtet. Der Assistent ist deshalb gesperrt."}),e.jsx(k,{to:"/admin/login",className:"text-sm font-medium text-brand-600 hover:underline dark:text-brand-400",children:"Zum Login"})]}),["database","schema","admin"].includes(n)&&e.jsx("div",{className:"mb-6 flex items-center justify-center gap-2",children:g.map((t,s)=>e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:`flex h-6 w-6 items-center justify-center rounded-full text-xs font-semibold ${sv(t.target.value),required:!0,autoFocus:!0,className:d})]}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"submit",disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Prüfe…":"Weiter"})]}),n==="database"&&e.jsxs("form",{onSubmit:S,children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Datenbank-Zugangsdaten"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Trage die Zugangsdaten der Datenbank auf diesem Server ein. Die Verbindung wird vor dem Speichern getestet."}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Host *"}),e.jsx("input",{required:!0,value:a.host,onChange:t=>h({...a,host:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Datenbankname *"}),e.jsx("input",{required:!0,value:a.name,onChange:t=>h({...a,name:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Benutzer *"}),e.jsx("input",{required:!0,value:a.user,onChange:t=>h({...a,user:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Passwort"}),e.jsx("input",{type:"password",value:a.password,onChange:t=>h({...a,password:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:i,children:"Zeichensatz"}),e.jsx("input",{value:a.charset,onChange:t=>h({...a,charset:t.target.value}),className:d})]}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"submit",disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Teste Verbindung…":"Verbindung testen & speichern"})]}),n==="schema"&&e.jsxs("div",{children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Datenbankstruktur"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Die Datenbankverbindung funktioniert. Jetzt legen wir die benötigten Tabellen an."}),w&&e.jsx("ul",{className:"mb-4 space-y-1 rounded-md bg-neutral-50 p-3 text-sm text-neutral-700 dark:bg-neutral-800 dark:text-neutral-300",children:w.map((t,s)=>e.jsx("li",{children:t},s))}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"button",onClick:A,disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Richte ein…":"Datenbankstruktur einrichten"})]}),n==="admin"&&e.jsxs("form",{onSubmit:C,children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Erster Admin-Account"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Lege den ersten Super-Admin-Account an, mit dem du dich anschließend einloggen kannst."}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Benutzername"}),e.jsx("input",{required:!0,autoFocus:!0,value:l.username,onChange:t=>p({...l,username:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Passwort"}),e.jsx("input",{type:"password",required:!0,minLength:8,value:l.password,onChange:t=>p({...l,password:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:i,children:"Passwort wiederholen"}),e.jsx("input",{type:"password",required:!0,minLength:8,value:l.password_confirmation,onChange:t=>p({...l,password_confirmation:t.target.value}),className:d})]}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"submit",disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Lege an…":"Admin-Account anlegen"})]}),n==="done"&&e.jsxs("div",{className:"text-center",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Fertig!"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Die Ersteinrichtung ist abgeschlossen. Du kannst dich jetzt mit deinem neuen Admin-Account anmelden."}),e.jsx(k,{to:"/admin/login",className:"inline-block w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600",children:"Zum Login"})]})]})]})}export{z as default}; +import{b as E,r as x,c as b,j as e,l as P,L as k}from"./index-Cc1wEeIX.js";const F={host:"",name:"",user:"",password:"",charset:"utf8mb4"},L={username:"",password:"",password_confirmation:""};function z(){E({title:"Ersteinrichtung",path:"/setup"});const[n,c]=x.useState("loading"),[m,r]=x.useState(""),[u,o]=x.useState(!1),[f,v]=x.useState(""),[a,h]=x.useState(F),[l,p]=x.useState(L),[w,y]=x.useState(null),N=()=>b.get("/setup/status").then(t=>(t.needs_setup?t.steps.admin.ok?c("done"):t.steps.schema.ok?c("admin"):c(t.steps.database.ok?"schema":"database"):c("locked"),t));x.useEffect(()=>{b.get("/setup/status").then(t=>c(t.needs_setup?"password":"locked")).catch(()=>c("locked"))},[]);const D=async t=>{t.preventDefault(),r(""),o(!0);try{await b.post("/setup/verify-password",{password:f}),await N()}catch(s){r(s.message)}finally{o(!1)}},S=async t=>{t.preventDefault(),r(""),o(!0);try{await b.post("/setup/database",a),await N()}catch(s){r(s.message)}finally{o(!1)}},A=async()=>{r(""),o(!0);try{const t=await b.post("/setup/migrate",{});y(t.actions),t.status.steps.schema.ok&&c("admin")}catch(t){r(t.message)}finally{o(!1)}},C=async t=>{if(t.preventDefault(),r(""),l.password!==l.password_confirmation){r("Die Passwörter stimmen nicht überein");return}o(!0);try{await b.post("/setup/admin",l),c("done")}catch(s){r(s.message)}finally{o(!1)}},d="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900",i="mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",g=[{key:"database",label:"Datenbank"},{key:"schema",label:"Struktur"},{key:"admin",label:"Admin-Account"}],j=g.findIndex(t=>t.key===n);return e.jsxs("div",{className:"flex min-h-screen flex-col items-center justify-center gap-6 bg-neutral-50 px-4 py-12 dark:bg-neutral-950",children:[e.jsx("img",{src:P,alt:"HifiPlanet",className:"h-16 w-auto sm:h-20"}),e.jsxs("div",{className:"w-full max-w-md rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900",children:[n==="loading"&&e.jsx("p",{className:"text-center text-sm text-neutral-400",children:"Lädt…"}),n==="locked"&&e.jsxs("div",{className:"text-center",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Bereits eingerichtet"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Diese Seite wurde bereits vollständig eingerichtet. Der Assistent ist deshalb gesperrt."}),e.jsx(k,{to:"/admin/login",className:"text-sm font-medium text-brand-600 hover:underline dark:text-brand-400",children:"Zum Login"})]}),["database","schema","admin"].includes(n)&&e.jsx("div",{className:"mb-6 flex items-center justify-center gap-2",children:g.map((t,s)=>e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("span",{className:`flex h-6 w-6 items-center justify-center rounded-full text-xs font-semibold ${sv(t.target.value),required:!0,autoFocus:!0,className:d})]}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"submit",disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Prüfe…":"Weiter"})]}),n==="database"&&e.jsxs("form",{onSubmit:S,children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Datenbank-Zugangsdaten"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Trage die Zugangsdaten der Datenbank auf diesem Server ein. Die Verbindung wird vor dem Speichern getestet."}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Host *"}),e.jsx("input",{required:!0,value:a.host,onChange:t=>h({...a,host:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Datenbankname *"}),e.jsx("input",{required:!0,value:a.name,onChange:t=>h({...a,name:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Benutzer *"}),e.jsx("input",{required:!0,value:a.user,onChange:t=>h({...a,user:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Passwort"}),e.jsx("input",{type:"password",value:a.password,onChange:t=>h({...a,password:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:i,children:"Zeichensatz"}),e.jsx("input",{value:a.charset,onChange:t=>h({...a,charset:t.target.value}),className:d})]}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"submit",disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Teste Verbindung…":"Verbindung testen & speichern"})]}),n==="schema"&&e.jsxs("div",{children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Datenbankstruktur"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Die Datenbankverbindung funktioniert. Jetzt legen wir die benötigten Tabellen an."}),w&&e.jsx("ul",{className:"mb-4 space-y-1 rounded-md bg-neutral-50 p-3 text-sm text-neutral-700 dark:bg-neutral-800 dark:text-neutral-300",children:w.map((t,s)=>e.jsx("li",{children:t},s))}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"button",onClick:A,disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Richte ein…":"Datenbankstruktur einrichten"})]}),n==="admin"&&e.jsxs("form",{onSubmit:C,children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Erster Admin-Account"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Lege den ersten Super-Admin-Account an, mit dem du dich anschließend einloggen kannst."}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Benutzername"}),e.jsx("input",{required:!0,autoFocus:!0,value:l.username,onChange:t=>p({...l,username:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-3",children:[e.jsx("label",{className:i,children:"Passwort"}),e.jsx("input",{type:"password",required:!0,minLength:8,value:l.password,onChange:t=>p({...l,password:t.target.value}),className:d})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("label",{className:i,children:"Passwort wiederholen"}),e.jsx("input",{type:"password",required:!0,minLength:8,value:l.password_confirmation,onChange:t=>p({...l,password_confirmation:t.target.value}),className:d})]}),m&&e.jsx("p",{className:"mb-4 text-sm text-red-600",children:m}),e.jsx("button",{type:"submit",disabled:u,className:"w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-60",children:u?"Lege an…":"Admin-Account anlegen"})]}),n==="done"&&e.jsxs("div",{className:"text-center",children:[e.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:"Fertig!"}),e.jsx("p",{className:"mb-6 text-sm text-neutral-500 dark:text-neutral-400",children:"Die Ersteinrichtung ist abgeschlossen. Du kannst dich jetzt mit deinem neuen Admin-Account anmelden."}),e.jsx(k,{to:"/admin/login",className:"inline-block w-full rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white hover:bg-brand-600",children:"Zum Login"})]})]})]})}export{z as default}; diff --git a/hifi/assets/SortableList-DRJ1jYgo.js b/hifi/assets/SortableList-DIXFCDYS.js similarity index 89% rename from hifi/assets/SortableList-DRJ1jYgo.js rename to hifi/assets/SortableList-DIXFCDYS.js index 77a3ddc..d90ba6a 100644 --- a/hifi/assets/SortableList-DRJ1jYgo.js +++ b/hifi/assets/SortableList-DIXFCDYS.js @@ -1 +1 @@ -import{j as o,c as x}from"./index-Tg8iNBwT.js";import{u as p,a as f,D as m,c as v,S as y,r as j,v as C,b as R,s as w,K as D,T as N,P as T,d as E,C as G}from"./sortable.esm-DhUbHeHx.js";import{G as I}from"./grip-vertical-By7l82Pv.js";function P({items:t,onReorder:s,children:n,as:e="ul",className:d="",disabled:i=!1}){const l=p(f(T,{activationConstraint:{distance:4}}),f(N,{activationConstraint:{delay:150,tolerance:6}}),f(D,{coordinateGetter:w})),c=({active:r,over:a})=>{if(!a||r.id===a.id)return;const h=t.findIndex(b=>b.id===r.id),S=t.findIndex(b=>b.id===a.id);s(R(t,h,S))},u=e==="tbody"?"tbody":e==="grid"?"div":"ul",g=e==="tbody"?"tr":e==="grid"?"div":"li";return o.jsx(m,{sensors:l,collisionDetection:v,onDragEnd:c,children:o.jsx(y,{items:t.map(r=>r.id),strategy:e==="grid"?j:C,disabled:i,children:o.jsx(u,{className:d,children:t.map(r=>o.jsx(K,{id:r.id,tag:g,disabled:i,children:a=>n(r,a)},r.id))})})})}function K({id:t,tag:s,disabled:n,children:e}){const{attributes:d,listeners:i,setNodeRef:l,setActivatorNodeRef:c,transform:u,transition:g,isDragging:r}=E({id:t,disabled:n}),a=n?null:o.jsx("button",{type:"button",ref:c,...d,...i,title:"Ziehen, um die Reihenfolge zu ändern","aria-label":"Reihenfolge ändern",className:"cursor-grab touch-none rounded p-1 text-neutral-400 hover:bg-neutral-100 hover:text-neutral-600 active:cursor-grabbing dark:hover:bg-neutral-800",children:o.jsx(I,{className:"h-4 w-4"})});return o.jsx(s,{ref:l,style:{transform:G.Translate.toString(u),transition:g,position:"relative",zIndex:r?10:void 0},className:r?"bg-white shadow-lg ring-1 ring-brand-500 dark:bg-neutral-900":void 0,children:e(a)})}async function A(t,s){return await x.put(`/reorder/${t}`,{ids:s.map(n=>n.id)}),s.map((n,e)=>({...n,sort_order:(e+1)*10}))}export{P as S,A as s}; +import{j as o,c as x}from"./index-Cc1wEeIX.js";import{u as p,a as f,D as m,c as v,S as y,r as j,v as C,b as R,s as w,K as D,T as N,P as T,d as E,C as G}from"./sortable.esm-D8IvDAze.js";import{G as I}from"./grip-vertical-0BUKE4NU.js";function P({items:t,onReorder:s,children:n,as:e="ul",className:d="",disabled:i=!1}){const l=p(f(T,{activationConstraint:{distance:4}}),f(N,{activationConstraint:{delay:150,tolerance:6}}),f(D,{coordinateGetter:w})),c=({active:r,over:a})=>{if(!a||r.id===a.id)return;const h=t.findIndex(b=>b.id===r.id),S=t.findIndex(b=>b.id===a.id);s(R(t,h,S))},u=e==="tbody"?"tbody":e==="grid"?"div":"ul",g=e==="tbody"?"tr":e==="grid"?"div":"li";return o.jsx(m,{sensors:l,collisionDetection:v,onDragEnd:c,children:o.jsx(y,{items:t.map(r=>r.id),strategy:e==="grid"?j:C,disabled:i,children:o.jsx(u,{className:d,children:t.map(r=>o.jsx(K,{id:r.id,tag:g,disabled:i,children:a=>n(r,a)},r.id))})})})}function K({id:t,tag:s,disabled:n,children:e}){const{attributes:d,listeners:i,setNodeRef:l,setActivatorNodeRef:c,transform:u,transition:g,isDragging:r}=E({id:t,disabled:n}),a=n?null:o.jsx("button",{type:"button",ref:c,...d,...i,title:"Ziehen, um die Reihenfolge zu ändern","aria-label":"Reihenfolge ändern",className:"cursor-grab touch-none rounded p-1 text-neutral-400 hover:bg-neutral-100 hover:text-neutral-600 active:cursor-grabbing dark:hover:bg-neutral-800",children:o.jsx(I,{className:"h-4 w-4"})});return o.jsx(s,{ref:l,style:{transform:G.Translate.toString(u),transition:g,position:"relative",zIndex:r?10:void 0},className:r?"bg-white shadow-lg ring-1 ring-brand-500 dark:bg-neutral-900":void 0,children:e(a)})}async function A(t,s){return await x.put(`/reorder/${t}`,{ids:s.map(n=>n.id)}),s.map((n,e)=>({...n,sort_order:(e+1)*10}))}export{P as S,A as s}; diff --git a/hifi/assets/TextStyleWidget-By2wExOQ.js b/hifi/assets/TextStyleWidget-DH0ih_Iq.js similarity index 97% rename from hifi/assets/TextStyleWidget-By2wExOQ.js rename to hifi/assets/TextStyleWidget-DH0ih_Iq.js index 0a67932..7827bf5 100644 --- a/hifi/assets/TextStyleWidget-By2wExOQ.js +++ b/hifi/assets/TextStyleWidget-DH0ih_Iq.js @@ -1 +1 @@ -import{w as g,r as l,c as x,j as t}from"./index-Tg8iNBwT.js";const y=[{label:"Standard",value:""},{label:"S (14px)",value:"14px"},{label:"M (16px)",value:"16px"},{label:"L (18px)",value:"18px"},{label:"XL (20px)",value:"20px"},{label:"XXL (24px)",value:"24px"},{label:"XXXL (28px)",value:"28px"},{label:"Groß (36px)",value:"36px"},{label:"Riesig (48px)",value:"48px"}],s={font_family:"",font_size:"",color:""};function k({fieldKey:o,previewText:p="Beispieltext",label:c="Stil"}){const b=g(),[a,n]=l.useState(s),[m,u]=l.useState(!0),[d,i]=l.useState("");l.useEffect(()=>{u(!0),x.get(`/text-styles/one?key=${encodeURIComponent(o)}`).then(e=>n({font_family:e.font_family||"",font_size:e.font_size||"",color:e.color||""})).catch(()=>n(s)).finally(()=>u(!1))},[o]);const r=async e=>{n(e),i("");try{await x.put("/text-styles",{field_key:o,...e})}catch(v){i(v.message)}};if(m)return null;const f={fontFamily:a.font_family||void 0,fontSize:a.font_size||void 0,color:a.color||void 0};return t.jsxs("div",{className:"mt-1.5 flex flex-wrap items-center gap-2 rounded-md border border-neutral-200 bg-neutral-50 p-2 dark:border-neutral-700 dark:bg-neutral-800/50",children:[t.jsx("span",{className:"text-xs font-medium uppercase tracking-wide text-neutral-400",children:c}),t.jsx("select",{value:a.font_family,onChange:e=>r({...a,font_family:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:b.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("select",{value:a.font_size,onChange:e=>r({...a,font_size:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:y.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("input",{type:"color",value:a.color||"#000000",onChange:e=>r({...a,color:e.target.value}),className:"h-7 w-9 cursor-pointer rounded border border-neutral-300 bg-white p-0.5 dark:border-neutral-700 dark:bg-neutral-900",title:"Textfarbe"}),t.jsx("button",{type:"button",onClick:()=>r(s),className:"rounded-md border border-neutral-300 px-2 py-1 text-xs text-neutral-500 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-400 dark:hover:bg-neutral-700",children:"Zurücksetzen"}),t.jsx("span",{className:"ml-1 rounded px-2 py-1 text-sm",style:f,children:p}),d&&t.jsx("span",{className:"text-xs text-red-600",children:d})]})}export{k as T}; +import{w as g,r as l,c as x,j as t}from"./index-Cc1wEeIX.js";const y=[{label:"Standard",value:""},{label:"S (14px)",value:"14px"},{label:"M (16px)",value:"16px"},{label:"L (18px)",value:"18px"},{label:"XL (20px)",value:"20px"},{label:"XXL (24px)",value:"24px"},{label:"XXXL (28px)",value:"28px"},{label:"Groß (36px)",value:"36px"},{label:"Riesig (48px)",value:"48px"}],s={font_family:"",font_size:"",color:""};function k({fieldKey:o,previewText:p="Beispieltext",label:c="Stil"}){const b=g(),[a,n]=l.useState(s),[m,u]=l.useState(!0),[d,i]=l.useState("");l.useEffect(()=>{u(!0),x.get(`/text-styles/one?key=${encodeURIComponent(o)}`).then(e=>n({font_family:e.font_family||"",font_size:e.font_size||"",color:e.color||""})).catch(()=>n(s)).finally(()=>u(!1))},[o]);const r=async e=>{n(e),i("");try{await x.put("/text-styles",{field_key:o,...e})}catch(v){i(v.message)}};if(m)return null;const f={fontFamily:a.font_family||void 0,fontSize:a.font_size||void 0,color:a.color||void 0};return t.jsxs("div",{className:"mt-1.5 flex flex-wrap items-center gap-2 rounded-md border border-neutral-200 bg-neutral-50 p-2 dark:border-neutral-700 dark:bg-neutral-800/50",children:[t.jsx("span",{className:"text-xs font-medium uppercase tracking-wide text-neutral-400",children:c}),t.jsx("select",{value:a.font_family,onChange:e=>r({...a,font_family:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:b.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("select",{value:a.font_size,onChange:e=>r({...a,font_size:e.target.value}),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-xs dark:border-neutral-700 dark:bg-neutral-900",children:y.map(e=>t.jsx("option",{value:e.value,children:e.label},e.label))}),t.jsx("input",{type:"color",value:a.color||"#000000",onChange:e=>r({...a,color:e.target.value}),className:"h-7 w-9 cursor-pointer rounded border border-neutral-300 bg-white p-0.5 dark:border-neutral-700 dark:bg-neutral-900",title:"Textfarbe"}),t.jsx("button",{type:"button",onClick:()=>r(s),className:"rounded-md border border-neutral-300 px-2 py-1 text-xs text-neutral-500 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-400 dark:hover:bg-neutral-700",children:"Zurücksetzen"}),t.jsx("span",{className:"ml-1 rounded px-2 py-1 text-sm",style:f,children:p}),d&&t.jsx("span",{className:"text-xs text-red-600",children:d})]})}export{k as T}; diff --git a/hifi/assets/UpdateSettings-_gVIigY0.js b/hifi/assets/UpdateSettings-CYjkz_68.js similarity index 99% rename from hifi/assets/UpdateSettings-_gVIigY0.js rename to hifi/assets/UpdateSettings-CYjkz_68.js index 49511e5..7c1df46 100644 --- a/hifi/assets/UpdateSettings-_gVIigY0.js +++ b/hifi/assets/UpdateSettings-CYjkz_68.js @@ -1 +1 @@ -import{r,j as e,c as i}from"./index-Tg8iNBwT.js";const z={download:"Herunterladen",extract:"Entpacken",backup:"Sichern",apply:"Installieren"};function C(a){return a?a.slice(0,7):"–"}function A(a){return a?new Date(a).toLocaleString("de-DE"):"–"}function O(){const[a,y]=r.useState(null),[n,S]=r.useState(null),[R,v]=r.useState(!0),[_,B]=r.useState(""),[h,E]=r.useState([]),[b,P]=r.useState(!1),[m,U]=r.useState(!1),[u,o]=r.useState({download:null,extract:null,backup:null,apply:null}),[g,p]=r.useState(""),[f,j]=r.useState(null),k=()=>{v(!0),B(""),Promise.all([i.get("/settings/update-status"),i.get("/settings/update-check")]).then(([t,s])=>{y(t),S(s)}).catch(t=>B(t.message)).finally(()=>v(!1)),i.get("/settings/update-branches").then(t=>E(t.branches||[])).catch(()=>E([]))},H=async t=>{P(!0),p(""),j(null);try{const s=await i.post("/settings/update-branch",{branch:t});S(s),y(d=>d&&{...d,branch:t})}catch(s){p(s.message)}finally{P(!1)}};r.useEffect(k,[]);const I=async()=>{U(!0),p(""),j(null),o({download:"busy",extract:null,backup:null,apply:null});try{const s=(await i.post("/settings/update-download",{})).run_id;o(l=>({...l,download:"done",extract:"busy"})),await i.post("/settings/update-extract",{run_id:s}),o(l=>({...l,extract:"done",backup:"busy"})),await i.post("/settings/update-backup",{}),o(l=>({...l,backup:"done",apply:"busy"}));const d=await i.post("/settings/update-apply",{run_id:s});o(l=>({...l,apply:"done"})),j(d.log||[]),k()}catch(t){o(s=>{const d=Object.keys(s).find(l=>s[l]==="busy");return d?{...s,[d]:"error"}:s}),p(t.message)}finally{U(!1)}};if(R)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const N=(a==null?void 0:a.capabilities)||{},D=N.zip?N.http_client?N.writable?null:"Das Website-Verzeichnis ist für PHP nicht beschreibbar - bitte Dateiberechtigungen prüfen.":"Diese Funktion benötigt ausgehende HTTPS-Verbindungen (curl oder allow_url_fopen), die auf diesem Server aktuell nicht verfügbar sind.":'Diese Funktion benötigt die PHP-Erweiterung "zip", die auf diesem Server aktuell nicht aktiviert ist. Bitte beim Hoster aktivieren lassen.',w=n==null?void 0:n.update_available,c=(a==null?void 0:a.branch)||"main",x=a==null?void 0:a.deployed_branch,L=!!x&&x!==c,F=h.some(t=>t.name===c)?h:[{name:c},...h];return e.jsx("div",{className:"max-w-2xl space-y-6",children:e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Updates aus Git"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Zieht den aktuellen Stand direkt vom Code-Repository und installiert ihn hier - ohne manuellen FTP-Upload. Passiert nur, wenn du unten aktiv auf "Update installieren" klickst, nie automatisch im Hintergrund.'}),_&&e.jsx("p",{className:"mb-3 text-sm text-red-600",children:_}),D?e.jsx("p",{className:"rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:D}):e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"mb-4",children:[e.jsx("label",{htmlFor:"update-branch",className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-200",children:"Branch"}),e.jsx("select",{id:"update-branch",value:c,onChange:t=>H(t.target.value),disabled:m||b,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm disabled:opacity-50 dark:border-neutral-700 dark:bg-neutral-800 dark:text-neutral-100",children:F.map(t=>e.jsxs("option",{value:t.name,children:[t.name,t.message?` – ${t.message}`:""]},t.name))}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:"Von diesem Branch wird installiert. Zum Zurückwechseln einfach wieder „main“ wählen und installieren – vorher wird wie immer eine Sicherung angelegt."})]}),e.jsxs("div",{className:"mb-4 grid grid-cols-2 gap-3 text-sm",children:[e.jsxs("div",{className:"rounded-md bg-neutral-50 p-3 dark:bg-neutral-800/50",children:[e.jsx("p",{className:"text-xs uppercase tracking-wide text-neutral-400",children:"Installiert"}),e.jsxs("p",{className:"font-mono text-neutral-800 dark:text-neutral-100",children:[C(a==null?void 0:a.deployed_sha),x&&e.jsxs("span",{className:"ml-2 font-sans text-xs text-neutral-400",children:["(",x,")"]})]}),e.jsx("p",{className:"text-xs text-neutral-400",children:A(a==null?void 0:a.deployed_at)})]}),e.jsxs("div",{className:"rounded-md bg-neutral-50 p-3 dark:bg-neutral-800/50",children:[e.jsx("p",{className:"text-xs uppercase tracking-wide text-neutral-400",children:"Neuester Stand"}),e.jsxs("p",{className:"font-mono text-neutral-800 dark:text-neutral-100",children:[C(n==null?void 0:n.latest_sha),e.jsxs("span",{className:"ml-2 font-sans text-xs text-neutral-400",children:["(",c,")"]})]}),(n==null?void 0:n.latest_message)&&e.jsx("p",{className:"truncate text-xs text-neutral-400",title:n.latest_message,children:n.latest_message})]})]}),L&&w?e.jsxs("p",{className:"mb-3 text-sm font-medium text-brand-600 dark:text-brand-400",children:["Installiert ist „",x,"“ – mit „Update installieren“ wechselst du auf „",c,"“."]}):w?e.jsx("p",{className:"mb-3 text-sm font-medium text-brand-600 dark:text-brand-400",children:"Update verfügbar."}):e.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:"Bereits auf dem neuesten Stand."}),e.jsxs("div",{className:"mb-3 flex gap-2",children:[e.jsx("button",{type:"button",onClick:k,disabled:m||b,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm font-medium hover:bg-neutral-50 disabled:opacity-50 dark:border-neutral-700 dark:hover:bg-neutral-800",children:"Nach Updates suchen"}),e.jsx("button",{type:"button",onClick:I,disabled:m||b||!w,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:m?"Installiere…":L?`Auf „${c}“ wechseln`:"Update installieren"})]}),(m||g)&&e.jsx("ul",{className:"mb-3 space-y-1 text-sm",children:Object.entries(z).map(([t,s])=>e.jsxs("li",{className:"flex items-center gap-2",children:[e.jsx("span",{className:u[t]==="done"?"text-green-600 dark:text-green-400":u[t]==="error"?"text-red-600":u[t]==="busy"?"text-brand-600 dark:text-brand-400":"text-neutral-300 dark:text-neutral-600",children:u[t]==="done"?"✓":u[t]==="error"?"✕":u[t]==="busy"?"…":"○"}),s]},t))}),g&&e.jsx("p",{className:"text-sm text-red-600",children:g}),f&&e.jsxs("div",{className:"mt-3 rounded-md bg-green-50 p-3 text-sm text-green-800 dark:bg-green-900/20 dark:text-green-300",children:[e.jsx("p",{className:"mb-1 font-semibold",children:"Update installiert."}),f.length>0&&e.jsxs("details",{children:[e.jsx("summary",{className:"cursor-pointer text-xs",children:"Details anzeigen"}),e.jsx("ul",{className:"mt-2 list-disc pl-5 text-xs",children:f.map((t,s)=>e.jsx("li",{children:t},s))})]})]})]})]})})}export{O as default}; +import{r,j as e,c as i}from"./index-Cc1wEeIX.js";const z={download:"Herunterladen",extract:"Entpacken",backup:"Sichern",apply:"Installieren"};function C(a){return a?a.slice(0,7):"–"}function A(a){return a?new Date(a).toLocaleString("de-DE"):"–"}function O(){const[a,y]=r.useState(null),[n,S]=r.useState(null),[R,v]=r.useState(!0),[_,B]=r.useState(""),[h,E]=r.useState([]),[b,P]=r.useState(!1),[m,U]=r.useState(!1),[u,o]=r.useState({download:null,extract:null,backup:null,apply:null}),[g,p]=r.useState(""),[f,j]=r.useState(null),k=()=>{v(!0),B(""),Promise.all([i.get("/settings/update-status"),i.get("/settings/update-check")]).then(([t,s])=>{y(t),S(s)}).catch(t=>B(t.message)).finally(()=>v(!1)),i.get("/settings/update-branches").then(t=>E(t.branches||[])).catch(()=>E([]))},H=async t=>{P(!0),p(""),j(null);try{const s=await i.post("/settings/update-branch",{branch:t});S(s),y(d=>d&&{...d,branch:t})}catch(s){p(s.message)}finally{P(!1)}};r.useEffect(k,[]);const I=async()=>{U(!0),p(""),j(null),o({download:"busy",extract:null,backup:null,apply:null});try{const s=(await i.post("/settings/update-download",{})).run_id;o(l=>({...l,download:"done",extract:"busy"})),await i.post("/settings/update-extract",{run_id:s}),o(l=>({...l,extract:"done",backup:"busy"})),await i.post("/settings/update-backup",{}),o(l=>({...l,backup:"done",apply:"busy"}));const d=await i.post("/settings/update-apply",{run_id:s});o(l=>({...l,apply:"done"})),j(d.log||[]),k()}catch(t){o(s=>{const d=Object.keys(s).find(l=>s[l]==="busy");return d?{...s,[d]:"error"}:s}),p(t.message)}finally{U(!1)}};if(R)return e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"});const N=(a==null?void 0:a.capabilities)||{},D=N.zip?N.http_client?N.writable?null:"Das Website-Verzeichnis ist für PHP nicht beschreibbar - bitte Dateiberechtigungen prüfen.":"Diese Funktion benötigt ausgehende HTTPS-Verbindungen (curl oder allow_url_fopen), die auf diesem Server aktuell nicht verfügbar sind.":'Diese Funktion benötigt die PHP-Erweiterung "zip", die auf diesem Server aktuell nicht aktiviert ist. Bitte beim Hoster aktivieren lassen.',w=n==null?void 0:n.update_available,c=(a==null?void 0:a.branch)||"main",x=a==null?void 0:a.deployed_branch,L=!!x&&x!==c,F=h.some(t=>t.name===c)?h:[{name:c},...h];return e.jsx("div",{className:"max-w-2xl space-y-6",children:e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Updates aus Git"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Zieht den aktuellen Stand direkt vom Code-Repository und installiert ihn hier - ohne manuellen FTP-Upload. Passiert nur, wenn du unten aktiv auf "Update installieren" klickst, nie automatisch im Hintergrund.'}),_&&e.jsx("p",{className:"mb-3 text-sm text-red-600",children:_}),D?e.jsx("p",{className:"rounded-md bg-amber-50 p-3 text-sm text-amber-800 dark:bg-amber-900/20 dark:text-amber-300",children:D}):e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"mb-4",children:[e.jsx("label",{htmlFor:"update-branch",className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-200",children:"Branch"}),e.jsx("select",{id:"update-branch",value:c,onChange:t=>H(t.target.value),disabled:m||b,className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm disabled:opacity-50 dark:border-neutral-700 dark:bg-neutral-800 dark:text-neutral-100",children:F.map(t=>e.jsxs("option",{value:t.name,children:[t.name,t.message?` – ${t.message}`:""]},t.name))}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:"Von diesem Branch wird installiert. Zum Zurückwechseln einfach wieder „main“ wählen und installieren – vorher wird wie immer eine Sicherung angelegt."})]}),e.jsxs("div",{className:"mb-4 grid grid-cols-2 gap-3 text-sm",children:[e.jsxs("div",{className:"rounded-md bg-neutral-50 p-3 dark:bg-neutral-800/50",children:[e.jsx("p",{className:"text-xs uppercase tracking-wide text-neutral-400",children:"Installiert"}),e.jsxs("p",{className:"font-mono text-neutral-800 dark:text-neutral-100",children:[C(a==null?void 0:a.deployed_sha),x&&e.jsxs("span",{className:"ml-2 font-sans text-xs text-neutral-400",children:["(",x,")"]})]}),e.jsx("p",{className:"text-xs text-neutral-400",children:A(a==null?void 0:a.deployed_at)})]}),e.jsxs("div",{className:"rounded-md bg-neutral-50 p-3 dark:bg-neutral-800/50",children:[e.jsx("p",{className:"text-xs uppercase tracking-wide text-neutral-400",children:"Neuester Stand"}),e.jsxs("p",{className:"font-mono text-neutral-800 dark:text-neutral-100",children:[C(n==null?void 0:n.latest_sha),e.jsxs("span",{className:"ml-2 font-sans text-xs text-neutral-400",children:["(",c,")"]})]}),(n==null?void 0:n.latest_message)&&e.jsx("p",{className:"truncate text-xs text-neutral-400",title:n.latest_message,children:n.latest_message})]})]}),L&&w?e.jsxs("p",{className:"mb-3 text-sm font-medium text-brand-600 dark:text-brand-400",children:["Installiert ist „",x,"“ – mit „Update installieren“ wechselst du auf „",c,"“."]}):w?e.jsx("p",{className:"mb-3 text-sm font-medium text-brand-600 dark:text-brand-400",children:"Update verfügbar."}):e.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:"Bereits auf dem neuesten Stand."}),e.jsxs("div",{className:"mb-3 flex gap-2",children:[e.jsx("button",{type:"button",onClick:k,disabled:m||b,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm font-medium hover:bg-neutral-50 disabled:opacity-50 dark:border-neutral-700 dark:hover:bg-neutral-800",children:"Nach Updates suchen"}),e.jsx("button",{type:"button",onClick:I,disabled:m||b||!w,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:m?"Installiere…":L?`Auf „${c}“ wechseln`:"Update installieren"})]}),(m||g)&&e.jsx("ul",{className:"mb-3 space-y-1 text-sm",children:Object.entries(z).map(([t,s])=>e.jsxs("li",{className:"flex items-center gap-2",children:[e.jsx("span",{className:u[t]==="done"?"text-green-600 dark:text-green-400":u[t]==="error"?"text-red-600":u[t]==="busy"?"text-brand-600 dark:text-brand-400":"text-neutral-300 dark:text-neutral-600",children:u[t]==="done"?"✓":u[t]==="error"?"✕":u[t]==="busy"?"…":"○"}),s]},t))}),g&&e.jsx("p",{className:"text-sm text-red-600",children:g}),f&&e.jsxs("div",{className:"mt-3 rounded-md bg-green-50 p-3 text-sm text-green-800 dark:bg-green-900/20 dark:text-green-300",children:[e.jsx("p",{className:"mb-1 font-semibold",children:"Update installiert."}),f.length>0&&e.jsxs("details",{children:[e.jsx("summary",{className:"cursor-pointer text-xs",children:"Details anzeigen"}),e.jsx("ul",{className:"mt-2 list-disc pl-5 text-xs",children:f.map((t,s)=>e.jsx("li",{children:t},s))})]})]})]})]})})}export{O as default}; diff --git a/hifi/assets/ViewOnSite-CVVA03Ho.js b/hifi/assets/ViewOnSite-CStAY6xT.js similarity index 84% rename from hifi/assets/ViewOnSite-CVVA03Ho.js rename to hifi/assets/ViewOnSite-CStAY6xT.js index fc65353..1bf7b41 100644 --- a/hifi/assets/ViewOnSite-CVVA03Ho.js +++ b/hifi/assets/ViewOnSite-CStAY6xT.js @@ -1 +1 @@ -import{j as n,E as a}from"./index-Tg8iNBwT.js";function i({to:e,label:r="Ansehen",className:t=""}){return e?n.jsxs("a",{href:e,target:"_blank",rel:"noopener noreferrer",title:"Auf der Website ansehen (neuer Tab)",className:`inline-flex items-center gap-1 text-xs font-medium text-neutral-500 hover:text-brand-600 dark:text-neutral-400 ${t}`,children:[n.jsx(a,{className:"h-3.5 w-3.5"}),r]}):null}export{i as V}; +import{j as n,E as a}from"./index-Cc1wEeIX.js";function i({to:e,label:r="Ansehen",className:t=""}){return e?n.jsxs("a",{href:e,target:"_blank",rel:"noopener noreferrer",title:"Auf der Website ansehen (neuer Tab)",className:`inline-flex items-center gap-1 text-xs font-medium text-neutral-500 hover:text-brand-600 dark:text-neutral-400 ${t}`,children:[n.jsx(a,{className:"h-3.5 w-3.5"}),r]}):null}export{i as V}; diff --git a/hifi/assets/WebsiteSettings-C9ZvZCtS.js b/hifi/assets/WebsiteSettings-I9lUY-Do.js similarity index 99% rename from hifi/assets/WebsiteSettings-C9ZvZCtS.js rename to hifi/assets/WebsiteSettings-I9lUY-Do.js index 29c8cf8..143835a 100644 --- a/hifi/assets/WebsiteSettings-C9ZvZCtS.js +++ b/hifi/assets/WebsiteSettings-I9lUY-Do.js @@ -1 +1 @@ -import{o as Me,w as Le,y as Ie,z as He,r as s,c as o,p as We,j as e,d as Oe}from"./index-Tg8iNBwT.js";import{I as S}from"./ImageUploadField-Ds8_wHup.js";import{S as Te}from"./SaveBar-BdqoV5a_.js";import"./resizeImage-C6PvAwh0.js";const me=[{key:"mon",label:"Montag"},{key:"tue",label:"Dienstag"},{key:"wed",label:"Mittwoch"},{key:"thu",label:"Donnerstag"},{key:"fri",label:"Freitag"},{key:"sat",label:"Samstag"},{key:"sun",label:"Sonntag"}],he=Object.fromEntries(me.map(i=>[i.key,{open:"09:00",close:"18:00",closed:!1}])),ue={phone:"",whatsapp:"",contact_email:"",address_street:"",address_zip:"",address_city:"",logo_path:"",logo_dark_path:"",business_hours:he,hero_image_path:"",ga_measurement_id:"",package_card_theme:"graphite",package_card_layout:"strip",package_wheel_hint_interval:8,package_card_width:210,package_card_height:480,vehicle_tile_width:240,vehicle_tile_height:180,gallery_card_text_x:0,gallery_card_text_y:100,site_font:"",page_loader_enabled:!0,price_note:"",price_note_en:""},Xe=[{value:"graphite",label:"Graphite Green",description:"Graphit über Bronze/Silber/Gold/Platin bis zur Onyx-Krönung."},{value:"deep-blue",label:"Deep Blue Luxury",description:"Kühles Blau, das sich über Grün zu Gold erwärmt."},{value:"warm-bronze",label:"Warm Bronze",description:"Durchgehend warmes Kupfer/Bronze/Amber bis zum Gold."}],Ue=[{value:"grid",label:"Raster",description:"Breite Kacheln, die responsiv in mehrere Zeilen umbrechen."},{value:"strip",label:"Scroll-Band",description:"Schmale, hochkant Kacheln in einer horizontal scrollbaren Reihe."},{value:"coverflow",label:"3D-Coverflow",description:"Kacheln drehen sich beim Wischen räumlich – die mittlere steht im Fokus."}];function et({section:i="company"}){const d=t=>t===i,u=Me(),xe=Le(),C=Ie(),z=He(),[B,D]=s.useState(""),[be,F]=s.useState(null),[A,G]=s.useState(!1),[P,R]=s.useState(""),ge=async t=>{t.preventDefault(),R(""),G(!0);try{const a=new FormData;a.append("name",B),a.append("file",be),await o.post("/custom-fonts",a),D(""),F(null),t.target.reset(),z(),u.success("Schriftart hochgeladen.")}catch(a){R(a.message)}finally{G(!1)}},pe=async t=>{if(confirm("Schriftart wirklich löschen? Felder, die sie noch verwenden, fallen danach auf die Standardschrift zurück."))try{await o.delete(`/custom-fonts/${t}`),z(),u.success("Schriftart gelöscht.")}catch(a){u.error(a.message)}},[r,b]=s.useState(ue),[ke,E]=s.useState(ue),[_e,fe]=s.useState(null),[ve,we]=s.useState(!0),[je,K]=s.useState(!1),[Je,m]=s.useState(!1),[M,L]=s.useState(""),[g,ye]=s.useState(null),I=s.useRef(null),[H,W]=s.useState(!1),Ne=(t,a)=>{const n=I.current.getBoundingClientRect();return{x:Math.max(0,Math.min(100,Math.round((t-n.left)/n.width*100))),y:Math.max(0,Math.min(100,Math.round((a-n.top)/n.height*100)))}},O=(t,a)=>{const{x:n,y:x}=Ne(t,a);b(Ke=>({...Ke,gallery_card_text_x:n,gallery_card_text_y:x})),m(!1)},Se=t=>{t.preventDefault(),t.currentTarget.setPointerCapture(t.pointerId),W(!0),O(t.clientX,t.clientY)},Ce=t=>{H&&O(t.clientX,t.clientY)},ze=t=>{W(!1),t.currentTarget.releasePointerCapture(t.pointerId)},[p,T]=s.useState(""),[Be,X]=s.useState(""),[v,U]=s.useState(""),[J,Z]=s.useState(!1),[De,$]=s.useState(!1),[V,Y]=s.useState(""),[Ze,k]=s.useState(!1),[h,q]=s.useState(""),[Fe,Q]=s.useState(""),[w,ee]=s.useState(""),[j,te]=s.useState(!1),[c,y]=s.useState(null),[Ae,ae]=s.useState(!1),[re,_]=s.useState(""),[$e,f]=s.useState(!1),[se,le]=s.useState(!1);s.useEffect(()=>{o.get("/site-settings").then(t=>{const a={phone:t.phone||"",whatsapp:t.whatsapp||"",contact_email:t.contact_email||"",address_street:t.address_street||"",address_zip:t.address_zip||"",address_city:t.address_city||"",logo_path:t.logo_path||"",logo_dark_path:t.logo_dark_path||"",business_hours:t.business_hours||he,hero_image_path:t.hero_image_path||"",ga_measurement_id:t.ga_measurement_id||"",package_card_theme:t.package_card_theme||"graphite",package_card_layout:t.package_card_layout||"strip",package_wheel_hint_interval:t.package_wheel_hint_interval||8,package_card_width:t.package_card_width||210,package_card_height:t.package_card_height||480,vehicle_tile_width:t.vehicle_tile_width||240,vehicle_tile_height:t.vehicle_tile_height||180,gallery_card_text_x:t.gallery_card_text_x??0,gallery_card_text_y:t.gallery_card_text_y??100,site_font:t.site_font||"",page_loader_enabled:t.page_loader_enabled===void 0?!0:!!t.page_loader_enabled,price_note:t.price_note||"",price_note_en:t.price_note_en||""};b(a),E(a)}).catch(t=>u.error(t.message)).finally(()=>we(!1)),i==="design"&&o.get("/gallery-brands").then(t=>ye(t.find(a=>a.cover_image_path)||null)).catch(()=>{}),i==="google"&&(o.get("/settings/analytics").then(t=>{T(t.ga_property_id||""),X(t.ga_property_id||""),Z(t.has_credentials)}).catch(()=>{}),ne())},[i]);const ne=()=>{o.get("/settings/google-reviews").then(t=>{q(t.place_id||""),Q(t.place_id||""),te(t.has_api_key),y(t)}).catch(()=>{})},Ge=async()=>{ae(!0),_(""),f(!1);try{const t=await o.post("/settings/google-reviews",{place_id:h,api_key:w});te(t.has_api_key),y(t),ee(""),Q(h),f(!0)}catch(t){throw _(t.message),t}finally{ae(!1)}},Pe=async()=>{le(!0),_("");try{const t=await o.post("/settings/google-reviews/refresh",{});y(t)}catch(t){_(t.message),ne()}finally{le(!1)}},Re=async()=>{$(!0),Y(""),k(!1);try{const t=await o.post("/settings/analytics",{ga_property_id:p,service_account_json:v});Z(t.has_credentials),U(""),X(p),k(!0)}catch(t){throw Y(t.message),t}finally{$(!1)}},l=(t,a)=>{b(n=>({...n,[t]:a})),m(!1)},N=(t,a,n)=>{b(x=>({...x,business_hours:{...x.business_hours,[t]:{...x.business_hours[t],[a]:n}}})),m(!1)},de=JSON.stringify(r)!==JSON.stringify(ke),ie=p!==Be||v!=="",oe=h!==Fe||w!=="",ce=de||i==="google"&&(ie||oe);We(ce,`website-settings-${i}`);const Ee=async t=>{t.preventDefault(),K(!0),L(""),m(!1);try{de&&await o.post("/site-settings",r),i==="google"&&ie&&await Re(),i==="google"&&oe&&await Ge(),E(r),m(!0),fe(new Date),u.success("Gespeichert.")}catch(a){L(a.message),u.error(`Speichern fehlgeschlagen: ${a.message}`)}finally{K(!1)}};return ve?e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsxs("form",{id:"website-settings-form",onSubmit:Ee,className:"max-w-2xl space-y-6",children:[d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Großes Titelbild der Startseite"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Das große Bild ganz oben auf der Startseite. Ohne eigenes Bild wird das Standardbild verwendet."}),e.jsx(S,{value:r.hero_image_path,onChange:t=>l("hero_image_path",t),label:"Bild",aspect:16/9})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Firmenlogo"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Ohne eigenes Logo wird das Standard-Logo dieser Vorlage angezeigt. Für den Dunkelmodus kann eine eigene Variante hinterlegt werden (z. B. mit heller statt dunkler Wortmarke)."}),e.jsxs("div",{className:"grid gap-4 sm:grid-cols-2",children:[e.jsx(S,{value:r.logo_path,onChange:t=>l("logo_path",t),label:"Logo (Hellmodus)"}),e.jsx(S,{value:r.logo_dark_path,onChange:t=>l("logo_dark_path",t),label:"Logo (Dunkelmodus)"})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Schriftart"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Gilt für die gesamte Website. Einzelne Startseiten-Sektionen können unter „Startseite“ davon abweichen."}),e.jsx("select",{value:r.site_font,onChange:t=>l("site_font",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:xe.map(t=>e.jsx("option",{value:t.value,children:t.label},t.label))})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Eigene Schriftarten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Eigene Schriftart-Dateien (WOFF2, WOFF, TTF oder OTF) hochladen - stehen danach in jeder Schriftart-Auswahl im Dashboard zusätzlich zur Wahl."}),C.length>0&&e.jsx("ul",{className:"mb-4 space-y-2",children:C.map(t=>e.jsxs("li",{className:"flex items-center justify-between gap-2 rounded-md border border-neutral-200 px-3 py-2 text-sm dark:border-neutral-700",children:[e.jsx("span",{style:{fontFamily:t.font_family},children:t.name}),e.jsx("button",{type:"button",onClick:()=>pe(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]},t.id))}),e.jsxs("form",{onSubmit:ge,className:"flex flex-wrap items-end gap-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name"}),e.jsx("input",{required:!0,value:B,onChange:t=>D(t.target.value),placeholder:"z. B. Firmenschrift",className:"rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Datei"}),e.jsx("input",{required:!0,type:"file",accept:".woff2,.woff,.ttf,.otf",onChange:t=>{var a;return F(((a=t.target.files)==null?void 0:a[0])||null)},className:"text-sm"})]}),e.jsx("button",{type:"submit",disabled:A,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:A?"Lädt hoch…":"Hochladen"})]}),P&&e.jsx("p",{className:"mt-2 text-sm text-red-600",children:P})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Seiten-Ladeanzeige"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Solange Daten und Bilder im sichtbaren Bereich einer Seite noch laden, bleibt der Inhalt ausgeblendet – verhindert, dass Bilder nachträglich "einpoppen". Das Lade-Symbol erscheint nur, wenn das länger als einen Augenblick dauert. Wirkt sich nicht auf das Dashboard und die Startseite aus, nur auf die übrigen Seiten der öffentlichen Website.'}),e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.page_loader_enabled,onChange:t=>l("page_loader_enabled",t.target.checked),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"Ladeanzeige aktivieren"]})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Kontaktdaten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Wird im Header, Footer und auf der Kontaktseite angezeigt."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Telefon"}),e.jsx("input",{value:r.phone,onChange:t=>l("phone",t.target.value),placeholder:"09373 20 62 390",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"WhatsApp Business Nummer"}),e.jsx("input",{value:r.whatsapp,onChange:t=>l("whatsapp",t.target.value),placeholder:"z. B. 09373 20 62 390",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Leer lassen, um den WhatsApp-Link im Header auszublenden."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"E-Mail"}),e.jsx("input",{type:"email",value:r.contact_email,onChange:t=>l("contact_email",t.target.value),placeholder:"info@hifi-planet-amorbach.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-[1fr_120px_1fr]",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Straße & Hausnummer"}),e.jsx("input",{value:r.address_street,onChange:t=>l("address_street",t.target.value),placeholder:"Boxbrunner Str. 20a",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"PLZ"}),e.jsx("input",{value:r.address_zip,onChange:t=>l("address_zip",t.target.value),placeholder:"63916",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Ort"}),e.jsx("input",{value:r.address_city,onChange:t=>l("address_city",t.target.value),placeholder:"Amorbach",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]})]})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Öffnungszeiten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Wird im Footer und auf der Kontaktseite angezeigt, inklusive dem "Geöffnet/Geschlossen"-Hinweis im Footer, der live gegen diese Zeiten rechnet.'}),e.jsx("div",{className:"space-y-2",children:me.map(t=>{const a=r.business_hours[t.key]||{open:"",close:"",closed:!1};return e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[e.jsx("span",{className:"w-24 shrink-0 text-sm text-neutral-600 dark:text-neutral-300",children:t.label}),e.jsxs("label",{className:"flex items-center gap-1.5 text-xs text-neutral-500 dark:text-neutral-400",children:[e.jsx("input",{type:"checkbox",checked:!a.closed,onChange:n=>N(t.key,"closed",!n.target.checked),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"geöffnet"]}),!a.closed&&e.jsxs(e.Fragment,{children:[e.jsx("input",{type:"time",value:a.open,onChange:n=>N(t.key,"open",n.target.value),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("span",{className:"text-neutral-400",children:"–"}),e.jsx("input",{type:"time",value:a.close,onChange:n=>N(t.key,"close",n.target.value),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]},t.key)})})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Hinweis unter den Paketpreisen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Erscheint klein unter jedem Paketpreis und im Kontaktformular – z. B. „inkl. MwSt. und Einbau“. So weiß der Kunde, was im Preis enthalten ist. Leer lassen, um keinen Hinweis anzuzeigen."}),e.jsxs("div",{className:"grid gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Deutsch"}),e.jsx("input",{value:r.price_note,onChange:t=>l("price_note",t.target.value),maxLength:150,placeholder:"inkl. MwSt. und Einbau",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Englisch (optional)"}),e.jsx("input",{value:r.price_note_en,onChange:t=>l("price_note_en",t.target.value),maxLength:150,placeholder:"incl. VAT and installation",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Paket-Kachel-Design"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Bestimmt die Farbgebung der Paket-Stufen auf jeder Fahrzeug-Modell-Seite (von der günstigsten bis zur teuersten Option)."}),e.jsx("div",{className:"grid gap-3 sm:grid-cols-3",children:Xe.map(t=>e.jsxs("label",{className:`cursor-pointer rounded-lg border p-3 text-sm transition ${r.package_card_theme===t.value?"border-brand-500 ring-2 ring-brand-500/40":"border-neutral-300 hover:border-neutral-400 dark:border-neutral-700 dark:hover:border-neutral-600"}`,children:[e.jsx("input",{type:"radio",name:"package_card_theme",value:t.value,checked:r.package_card_theme===t.value,onChange:a=>l("package_card_theme",a.target.value),className:"sr-only"}),e.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:t.label}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]},t.value))})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Kachel-Layout"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Bestimmt, wie die Paket-Stufen auf jeder Fahrzeug-Modell-Seite angeordnet werden."}),e.jsx("div",{className:"grid gap-3 sm:grid-cols-3",children:Ue.map(t=>e.jsxs("label",{className:`cursor-pointer rounded-lg border p-3 text-sm transition ${r.package_card_layout===t.value?"border-brand-500 ring-2 ring-brand-500/40":"border-neutral-300 hover:border-neutral-400 dark:border-neutral-700 dark:hover:border-neutral-600"}`,children:[e.jsx("input",{type:"radio",name:"package_card_layout",value:t.value,checked:r.package_card_layout===t.value,onChange:a=>l("package_card_layout",a.target.value),className:"sr-only"}),e.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:t.label}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]},t.value))}),e.jsxs("div",{className:"mt-5 max-w-xs",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Mausrad-Hinweis: Wiederholung (Sekunden)"}),e.jsx("input",{type:"number",min:"2",max:"120",value:r.package_wheel_hint_interval,onChange:t=>l("package_wheel_hint_interval",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:'Nur bei Scroll-Band/3D-Coverflow: Solange ein Besucher noch auf der ersten Kachel steht, wird der "mit dem Mausrad blättern"-Hinweis in diesem Abstand wiederholt.'})]}),e.jsxs("div",{className:"mt-5 grid max-w-xs gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Breite (px)"}),e.jsx("input",{type:"number",min:"80",max:"600",value:r.package_card_width,onChange:t=>l("package_card_width",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Höhe (px)"}),e.jsx("input",{type:"number",min:"80",max:"900",value:r.package_card_height,onChange:t=>l("package_card_height",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx("p",{className:"text-xs text-neutral-400 sm:col-span-2",children:'Bei „Raster" bestimmt die Breite stattdessen, wie viele Kacheln pro Zeile passen.'})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Marken-/Modell-Kacheln"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Größe der Kacheln unter „Fahrzeuge wählen" und auf der Marken-Detailseite.'}),e.jsxs("div",{className:"grid max-w-xs gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Breite (px)"}),e.jsx("input",{type:"number",min:"80",max:"600",value:r.vehicle_tile_width,onChange:t=>l("vehicle_tile_width",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Höhe (px)"}),e.jsx("input",{type:"number",min:"80",max:"600",value:r.vehicle_tile_height,onChange:t=>l("vehicle_tile_height",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Bildergalerie-Kacheln"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Position des Marken-/Projekt-Namens auf den Kacheln der Bildergalerie-Übersicht und der Marken-Detailseite."}),e.jsxs("div",{className:"grid gap-4 sm:grid-cols-[16rem_1fr] sm:items-start",children:[e.jsxs("div",{children:[e.jsxs("div",{ref:I,className:"relative aspect-[4/3] select-none overflow-hidden rounded-xl bg-neutral-900 shadow-sm",children:[g?e.jsx("img",{src:g.cover_image_path,alt:"",draggable:!1,className:"h-full w-full object-cover"}):e.jsx("div",{className:"h-full w-full bg-gradient-to-br from-neutral-700 to-neutral-900"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent"}),e.jsx("span",{onPointerDown:Se,onPointerMove:Ce,onPointerUp:ze,style:{...Oe(r.gallery_card_text_x,r.gallery_card_text_y,{x:0,y:100}),touchAction:"none"},className:`absolute select-none whitespace-nowrap rounded p-3 text-sm font-extrabold text-white transition-colors ${H?"cursor-grabbing bg-white/10 ring-2 ring-brand-400":"cursor-grab hover:bg-white/10"}`,children:g?g.name:"Beispiel-Marke"})]}),e.jsx("p",{className:"mt-1.5 text-center text-xs text-neutral-400",children:"Namen zum Verschieben ziehen"})]}),e.jsxs("div",{className:"flex flex-col gap-3 sm:pt-1",children:[e.jsxs("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:["Position:"," ",e.jsxs("span",{className:"font-mono font-semibold text-neutral-700 dark:text-neutral-200",children:[r.gallery_card_text_x,"% / ",r.gallery_card_text_y,"%"]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl waagerecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_x",0),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Links"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_x",50),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_x",100),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Rechts"})]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl senkrecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_y",0),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Oben"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_y",50),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_y",100),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Unten"})]})]})]})]})]}),d("google")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Wird erst geladen, nachdem ein Besucher der Statistik-Kategorie im Cookie-Banner zugestimmt hat. Leer lassen, um Google Analytics zu deaktivieren."}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Measurement-ID"}),e.jsx("input",{value:r.ga_measurement_id,onChange:t=>l("ga_measurement_id",t.target.value),placeholder:"G-XXXXXXXXXX",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"mt-5 border-t border-neutral-200 pt-5 dark:border-neutral-800",children:[e.jsx("h3",{className:"mb-1 text-sm font-semibold text-neutral-900 dark:text-white",children:"Dashboard-Anbindung (optional)"}),e.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:"Zeigt Besucherzahlen direkt in deinem Admin-Dashboard an. Braucht ein Google-Cloud-Service-Account mit Lesezugriff auf diese GA4-Property."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Property-ID"}),e.jsx("input",{value:p,onChange:t=>{T(t.target.value),k(!1)},placeholder:"z. B. 123456789",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Nicht die Measurement-ID (G-...) - zu finden unter GA4 → Verwaltung → Property-Details."})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Service-Account-JSON-Schlüssel ",J?"(leer lassen = unverändert)":""]}),e.jsx("textarea",{rows:4,value:v,onChange:t=>{U(t.target.value),k(!1)},placeholder:J?'{ "type": "service_account", ... } (bereits hinterlegt)':'{ "type": "service_account", ... }',className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 font-mono text-xs dark:border-neutral-700 dark:bg-neutral-900"})]})]}),V&&e.jsx("p",{className:"mt-2 text-sm text-red-600",children:V})]})]}),d("google")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google-Rezensionen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Zeigt die echte Google-Bewertung und die aktuellsten Rezensionen auf der Startseite an, statt der fest eingetragenen Beispiel-Texte. Wird einmal täglich automatisch aktualisiert (nie bei einem Seitenbesuch selbst) – die Seite zeigt also immer den letzten erfolgreich abgerufenen Stand."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Place-ID"}),e.jsx("input",{value:h,onChange:t=>{q(t.target.value),f(!1)},placeholder:"z. B. ChIJN1t_tDeuEmsRUsoyG83frY4",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:["Eindeutige Google-Kennung eures Eintrags – zu finden über den"," ",e.jsx("a",{href:"https://developers.google.com/maps/documentation/places/web-service/place-id#find-id",target:"_blank",rel:"noopener noreferrer",className:"underline hover:text-brand-600",children:"Google Place ID Finder"}),"."]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Places-API-Key ",j?"(leer lassen = unverändert)":""]}),e.jsx("input",{value:w,onChange:t=>{ee(t.target.value),f(!1)},placeholder:j?"••••••••••••••••••••• (bereits hinterlegt)":"AIzaSy…",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 font-mono text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Aus der Google-Cloud-Console, mit aktivierter „Places API (New)“."})]})]}),re&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:re}),e.jsx("div",{className:"mt-3 flex flex-wrap items-center gap-3",children:e.jsx("button",{type:"button",onClick:Pe,disabled:se||!h||!j,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:se?"Aktualisiere…":"Jetzt aktualisieren"})}),c&&e.jsxs("div",{className:"mt-4 rounded-md bg-neutral-50 p-3 text-sm dark:bg-neutral-800/50",children:[c.rating!=null?e.jsxs("p",{className:"text-neutral-700 dark:text-neutral-300",children:["Aktuell hinterlegt: ",e.jsxs("strong",{children:[c.rating," ★"]})," (",c.rating_count," Bewertungen)",c.updated_at&&e.jsxs(e.Fragment,{children:[" – zuletzt aktualisiert am ",new Date(c.updated_at.replace(" ","T")).toLocaleString("de-DE")]})]}):e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:"Noch keine erfolgreiche Aktualisierung – die Startseite zeigt bis dahin weiter die Beispiel-Rezensionen."}),c.error&&e.jsxs("p",{className:"mt-1 text-red-600",children:["Letzter Fehler: ",c.error]})]})]}),M&&e.jsx("p",{className:"text-sm text-red-600",children:M}),e.jsx(Te,{dirty:ce,busy:je||De||Ae,savedAt:_e,form:"website-settings-form"})]})}export{et as default}; +import{o as Me,w as Le,y as Ie,z as He,r as s,c as o,p as We,j as e,d as Oe}from"./index-Cc1wEeIX.js";import{I as S}from"./ImageUploadField-DYOhdPMm.js";import{S as Te}from"./SaveBar-Cr-Ys8TW.js";import"./resizeImage-C6PvAwh0.js";const me=[{key:"mon",label:"Montag"},{key:"tue",label:"Dienstag"},{key:"wed",label:"Mittwoch"},{key:"thu",label:"Donnerstag"},{key:"fri",label:"Freitag"},{key:"sat",label:"Samstag"},{key:"sun",label:"Sonntag"}],he=Object.fromEntries(me.map(i=>[i.key,{open:"09:00",close:"18:00",closed:!1}])),ue={phone:"",whatsapp:"",contact_email:"",address_street:"",address_zip:"",address_city:"",logo_path:"",logo_dark_path:"",business_hours:he,hero_image_path:"",ga_measurement_id:"",package_card_theme:"graphite",package_card_layout:"strip",package_wheel_hint_interval:8,package_card_width:210,package_card_height:480,vehicle_tile_width:240,vehicle_tile_height:180,gallery_card_text_x:0,gallery_card_text_y:100,site_font:"",page_loader_enabled:!0,price_note:"",price_note_en:""},Xe=[{value:"graphite",label:"Graphite Green",description:"Graphit über Bronze/Silber/Gold/Platin bis zur Onyx-Krönung."},{value:"deep-blue",label:"Deep Blue Luxury",description:"Kühles Blau, das sich über Grün zu Gold erwärmt."},{value:"warm-bronze",label:"Warm Bronze",description:"Durchgehend warmes Kupfer/Bronze/Amber bis zum Gold."}],Ue=[{value:"grid",label:"Raster",description:"Breite Kacheln, die responsiv in mehrere Zeilen umbrechen."},{value:"strip",label:"Scroll-Band",description:"Schmale, hochkant Kacheln in einer horizontal scrollbaren Reihe."},{value:"coverflow",label:"3D-Coverflow",description:"Kacheln drehen sich beim Wischen räumlich – die mittlere steht im Fokus."}];function et({section:i="company"}){const d=t=>t===i,u=Me(),xe=Le(),C=Ie(),z=He(),[B,D]=s.useState(""),[be,F]=s.useState(null),[A,G]=s.useState(!1),[P,R]=s.useState(""),ge=async t=>{t.preventDefault(),R(""),G(!0);try{const a=new FormData;a.append("name",B),a.append("file",be),await o.post("/custom-fonts",a),D(""),F(null),t.target.reset(),z(),u.success("Schriftart hochgeladen.")}catch(a){R(a.message)}finally{G(!1)}},pe=async t=>{if(confirm("Schriftart wirklich löschen? Felder, die sie noch verwenden, fallen danach auf die Standardschrift zurück."))try{await o.delete(`/custom-fonts/${t}`),z(),u.success("Schriftart gelöscht.")}catch(a){u.error(a.message)}},[r,b]=s.useState(ue),[ke,E]=s.useState(ue),[_e,fe]=s.useState(null),[ve,we]=s.useState(!0),[je,K]=s.useState(!1),[Je,m]=s.useState(!1),[M,L]=s.useState(""),[g,ye]=s.useState(null),I=s.useRef(null),[H,W]=s.useState(!1),Ne=(t,a)=>{const n=I.current.getBoundingClientRect();return{x:Math.max(0,Math.min(100,Math.round((t-n.left)/n.width*100))),y:Math.max(0,Math.min(100,Math.round((a-n.top)/n.height*100)))}},O=(t,a)=>{const{x:n,y:x}=Ne(t,a);b(Ke=>({...Ke,gallery_card_text_x:n,gallery_card_text_y:x})),m(!1)},Se=t=>{t.preventDefault(),t.currentTarget.setPointerCapture(t.pointerId),W(!0),O(t.clientX,t.clientY)},Ce=t=>{H&&O(t.clientX,t.clientY)},ze=t=>{W(!1),t.currentTarget.releasePointerCapture(t.pointerId)},[p,T]=s.useState(""),[Be,X]=s.useState(""),[v,U]=s.useState(""),[J,Z]=s.useState(!1),[De,$]=s.useState(!1),[V,Y]=s.useState(""),[Ze,k]=s.useState(!1),[h,q]=s.useState(""),[Fe,Q]=s.useState(""),[w,ee]=s.useState(""),[j,te]=s.useState(!1),[c,y]=s.useState(null),[Ae,ae]=s.useState(!1),[re,_]=s.useState(""),[$e,f]=s.useState(!1),[se,le]=s.useState(!1);s.useEffect(()=>{o.get("/site-settings").then(t=>{const a={phone:t.phone||"",whatsapp:t.whatsapp||"",contact_email:t.contact_email||"",address_street:t.address_street||"",address_zip:t.address_zip||"",address_city:t.address_city||"",logo_path:t.logo_path||"",logo_dark_path:t.logo_dark_path||"",business_hours:t.business_hours||he,hero_image_path:t.hero_image_path||"",ga_measurement_id:t.ga_measurement_id||"",package_card_theme:t.package_card_theme||"graphite",package_card_layout:t.package_card_layout||"strip",package_wheel_hint_interval:t.package_wheel_hint_interval||8,package_card_width:t.package_card_width||210,package_card_height:t.package_card_height||480,vehicle_tile_width:t.vehicle_tile_width||240,vehicle_tile_height:t.vehicle_tile_height||180,gallery_card_text_x:t.gallery_card_text_x??0,gallery_card_text_y:t.gallery_card_text_y??100,site_font:t.site_font||"",page_loader_enabled:t.page_loader_enabled===void 0?!0:!!t.page_loader_enabled,price_note:t.price_note||"",price_note_en:t.price_note_en||""};b(a),E(a)}).catch(t=>u.error(t.message)).finally(()=>we(!1)),i==="design"&&o.get("/gallery-brands").then(t=>ye(t.find(a=>a.cover_image_path)||null)).catch(()=>{}),i==="google"&&(o.get("/settings/analytics").then(t=>{T(t.ga_property_id||""),X(t.ga_property_id||""),Z(t.has_credentials)}).catch(()=>{}),ne())},[i]);const ne=()=>{o.get("/settings/google-reviews").then(t=>{q(t.place_id||""),Q(t.place_id||""),te(t.has_api_key),y(t)}).catch(()=>{})},Ge=async()=>{ae(!0),_(""),f(!1);try{const t=await o.post("/settings/google-reviews",{place_id:h,api_key:w});te(t.has_api_key),y(t),ee(""),Q(h),f(!0)}catch(t){throw _(t.message),t}finally{ae(!1)}},Pe=async()=>{le(!0),_("");try{const t=await o.post("/settings/google-reviews/refresh",{});y(t)}catch(t){_(t.message),ne()}finally{le(!1)}},Re=async()=>{$(!0),Y(""),k(!1);try{const t=await o.post("/settings/analytics",{ga_property_id:p,service_account_json:v});Z(t.has_credentials),U(""),X(p),k(!0)}catch(t){throw Y(t.message),t}finally{$(!1)}},l=(t,a)=>{b(n=>({...n,[t]:a})),m(!1)},N=(t,a,n)=>{b(x=>({...x,business_hours:{...x.business_hours,[t]:{...x.business_hours[t],[a]:n}}})),m(!1)},de=JSON.stringify(r)!==JSON.stringify(ke),ie=p!==Be||v!=="",oe=h!==Fe||w!=="",ce=de||i==="google"&&(ie||oe);We(ce,`website-settings-${i}`);const Ee=async t=>{t.preventDefault(),K(!0),L(""),m(!1);try{de&&await o.post("/site-settings",r),i==="google"&&ie&&await Re(),i==="google"&&oe&&await Ge(),E(r),m(!0),fe(new Date),u.success("Gespeichert.")}catch(a){L(a.message),u.error(`Speichern fehlgeschlagen: ${a.message}`)}finally{K(!1)}};return ve?e.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}):e.jsxs("form",{id:"website-settings-form",onSubmit:Ee,className:"max-w-2xl space-y-6",children:[d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Großes Titelbild der Startseite"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Das große Bild ganz oben auf der Startseite. Ohne eigenes Bild wird das Standardbild verwendet."}),e.jsx(S,{value:r.hero_image_path,onChange:t=>l("hero_image_path",t),label:"Bild",aspect:16/9})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Firmenlogo"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Ohne eigenes Logo wird das Standard-Logo dieser Vorlage angezeigt. Für den Dunkelmodus kann eine eigene Variante hinterlegt werden (z. B. mit heller statt dunkler Wortmarke)."}),e.jsxs("div",{className:"grid gap-4 sm:grid-cols-2",children:[e.jsx(S,{value:r.logo_path,onChange:t=>l("logo_path",t),label:"Logo (Hellmodus)"}),e.jsx(S,{value:r.logo_dark_path,onChange:t=>l("logo_dark_path",t),label:"Logo (Dunkelmodus)"})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Schriftart"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Gilt für die gesamte Website. Einzelne Startseiten-Sektionen können unter „Startseite“ davon abweichen."}),e.jsx("select",{value:r.site_font,onChange:t=>l("site_font",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900",children:xe.map(t=>e.jsx("option",{value:t.value,children:t.label},t.label))})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Eigene Schriftarten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Eigene Schriftart-Dateien (WOFF2, WOFF, TTF oder OTF) hochladen - stehen danach in jeder Schriftart-Auswahl im Dashboard zusätzlich zur Wahl."}),C.length>0&&e.jsx("ul",{className:"mb-4 space-y-2",children:C.map(t=>e.jsxs("li",{className:"flex items-center justify-between gap-2 rounded-md border border-neutral-200 px-3 py-2 text-sm dark:border-neutral-700",children:[e.jsx("span",{style:{fontFamily:t.font_family},children:t.name}),e.jsx("button",{type:"button",onClick:()=>pe(t.id),className:"text-red-600 hover:underline",children:"Löschen"})]},t.id))}),e.jsxs("form",{onSubmit:ge,className:"flex flex-wrap items-end gap-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Name"}),e.jsx("input",{required:!0,value:B,onChange:t=>D(t.target.value),placeholder:"z. B. Firmenschrift",className:"rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Datei"}),e.jsx("input",{required:!0,type:"file",accept:".woff2,.woff,.ttf,.otf",onChange:t=>{var a;return F(((a=t.target.files)==null?void 0:a[0])||null)},className:"text-sm"})]}),e.jsx("button",{type:"submit",disabled:A,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:A?"Lädt hoch…":"Hochladen"})]}),P&&e.jsx("p",{className:"mt-2 text-sm text-red-600",children:P})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Seiten-Ladeanzeige"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Solange Daten und Bilder im sichtbaren Bereich einer Seite noch laden, bleibt der Inhalt ausgeblendet – verhindert, dass Bilder nachträglich "einpoppen". Das Lade-Symbol erscheint nur, wenn das länger als einen Augenblick dauert. Wirkt sich nicht auf das Dashboard und die Startseite aus, nur auf die übrigen Seiten der öffentlichen Website.'}),e.jsxs("label",{className:"flex items-center gap-2 text-sm text-neutral-700 dark:text-neutral-300",children:[e.jsx("input",{type:"checkbox",checked:r.page_loader_enabled,onChange:t=>l("page_loader_enabled",t.target.checked),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"Ladeanzeige aktivieren"]})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Kontaktdaten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Wird im Header, Footer und auf der Kontaktseite angezeigt."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Telefon"}),e.jsx("input",{value:r.phone,onChange:t=>l("phone",t.target.value),placeholder:"09373 20 62 390",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"WhatsApp Business Nummer"}),e.jsx("input",{value:r.whatsapp,onChange:t=>l("whatsapp",t.target.value),placeholder:"z. B. 09373 20 62 390",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Leer lassen, um den WhatsApp-Link im Header auszublenden."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"E-Mail"}),e.jsx("input",{type:"email",value:r.contact_email,onChange:t=>l("contact_email",t.target.value),placeholder:"info@hifi-planet-amorbach.de",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-[1fr_120px_1fr]",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Straße & Hausnummer"}),e.jsx("input",{value:r.address_street,onChange:t=>l("address_street",t.target.value),placeholder:"Boxbrunner Str. 20a",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"PLZ"}),e.jsx("input",{value:r.address_zip,onChange:t=>l("address_zip",t.target.value),placeholder:"63916",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Ort"}),e.jsx("input",{value:r.address_city,onChange:t=>l("address_city",t.target.value),placeholder:"Amorbach",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]})]})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Öffnungszeiten"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Wird im Footer und auf der Kontaktseite angezeigt, inklusive dem "Geöffnet/Geschlossen"-Hinweis im Footer, der live gegen diese Zeiten rechnet.'}),e.jsx("div",{className:"space-y-2",children:me.map(t=>{const a=r.business_hours[t.key]||{open:"",close:"",closed:!1};return e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[e.jsx("span",{className:"w-24 shrink-0 text-sm text-neutral-600 dark:text-neutral-300",children:t.label}),e.jsxs("label",{className:"flex items-center gap-1.5 text-xs text-neutral-500 dark:text-neutral-400",children:[e.jsx("input",{type:"checkbox",checked:!a.closed,onChange:n=>N(t.key,"closed",!n.target.checked),className:"h-4 w-4 rounded border-neutral-300 text-brand-600 focus:ring-brand-500"}),"geöffnet"]}),!a.closed&&e.jsxs(e.Fragment,{children:[e.jsx("input",{type:"time",value:a.open,onChange:n=>N(t.key,"open",n.target.value),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("span",{className:"text-neutral-400",children:"–"}),e.jsx("input",{type:"time",value:a.close,onChange:n=>N(t.key,"close",n.target.value),className:"rounded-md border border-neutral-300 bg-white px-2 py-1 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]},t.key)})})]}),d("company")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Hinweis unter den Paketpreisen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Erscheint klein unter jedem Paketpreis und im Kontaktformular – z. B. „inkl. MwSt. und Einbau“. So weiß der Kunde, was im Preis enthalten ist. Leer lassen, um keinen Hinweis anzuzeigen."}),e.jsxs("div",{className:"grid gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Deutsch"}),e.jsx("input",{value:r.price_note,onChange:t=>l("price_note",t.target.value),maxLength:150,placeholder:"inkl. MwSt. und Einbau",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Englisch (optional)"}),e.jsx("input",{value:r.price_note_en,onChange:t=>l("price_note_en",t.target.value),maxLength:150,placeholder:"incl. VAT and installation",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Paket-Kachel-Design"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Bestimmt die Farbgebung der Paket-Stufen auf jeder Fahrzeug-Modell-Seite (von der günstigsten bis zur teuersten Option)."}),e.jsx("div",{className:"grid gap-3 sm:grid-cols-3",children:Xe.map(t=>e.jsxs("label",{className:`cursor-pointer rounded-lg border p-3 text-sm transition ${r.package_card_theme===t.value?"border-brand-500 ring-2 ring-brand-500/40":"border-neutral-300 hover:border-neutral-400 dark:border-neutral-700 dark:hover:border-neutral-600"}`,children:[e.jsx("input",{type:"radio",name:"package_card_theme",value:t.value,checked:r.package_card_theme===t.value,onChange:a=>l("package_card_theme",a.target.value),className:"sr-only"}),e.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:t.label}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]},t.value))})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Kachel-Layout"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Bestimmt, wie die Paket-Stufen auf jeder Fahrzeug-Modell-Seite angeordnet werden."}),e.jsx("div",{className:"grid gap-3 sm:grid-cols-3",children:Ue.map(t=>e.jsxs("label",{className:`cursor-pointer rounded-lg border p-3 text-sm transition ${r.package_card_layout===t.value?"border-brand-500 ring-2 ring-brand-500/40":"border-neutral-300 hover:border-neutral-400 dark:border-neutral-700 dark:hover:border-neutral-600"}`,children:[e.jsx("input",{type:"radio",name:"package_card_layout",value:t.value,checked:r.package_card_layout===t.value,onChange:a=>l("package_card_layout",a.target.value),className:"sr-only"}),e.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:t.label}),e.jsx("p",{className:"mt-1 text-xs text-neutral-500 dark:text-neutral-400",children:t.description})]},t.value))}),e.jsxs("div",{className:"mt-5 max-w-xs",children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Mausrad-Hinweis: Wiederholung (Sekunden)"}),e.jsx("input",{type:"number",min:"2",max:"120",value:r.package_wheel_hint_interval,onChange:t=>l("package_wheel_hint_interval",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:'Nur bei Scroll-Band/3D-Coverflow: Solange ein Besucher noch auf der ersten Kachel steht, wird der "mit dem Mausrad blättern"-Hinweis in diesem Abstand wiederholt.'})]}),e.jsxs("div",{className:"mt-5 grid max-w-xs gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Breite (px)"}),e.jsx("input",{type:"number",min:"80",max:"600",value:r.package_card_width,onChange:t=>l("package_card_width",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Höhe (px)"}),e.jsx("input",{type:"number",min:"80",max:"900",value:r.package_card_height,onChange:t=>l("package_card_height",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsx("p",{className:"text-xs text-neutral-400 sm:col-span-2",children:'Bei „Raster" bestimmt die Breite stattdessen, wie viele Kacheln pro Zeile passen.'})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Marken-/Modell-Kacheln"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:'Größe der Kacheln unter „Fahrzeuge wählen" und auf der Marken-Detailseite.'}),e.jsxs("div",{className:"grid max-w-xs gap-3 sm:grid-cols-2",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Breite (px)"}),e.jsx("input",{type:"number",min:"80",max:"600",value:r.vehicle_tile_width,onChange:t=>l("vehicle_tile_width",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Höhe (px)"}),e.jsx("input",{type:"number",min:"80",max:"600",value:r.vehicle_tile_height,onChange:t=>l("vehicle_tile_height",t.target.value),className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]})]})]}),d("design")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Bildergalerie-Kacheln"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Position des Marken-/Projekt-Namens auf den Kacheln der Bildergalerie-Übersicht und der Marken-Detailseite."}),e.jsxs("div",{className:"grid gap-4 sm:grid-cols-[16rem_1fr] sm:items-start",children:[e.jsxs("div",{children:[e.jsxs("div",{ref:I,className:"relative aspect-[4/3] select-none overflow-hidden rounded-xl bg-neutral-900 shadow-sm",children:[g?e.jsx("img",{src:g.cover_image_path,alt:"",draggable:!1,className:"h-full w-full object-cover"}):e.jsx("div",{className:"h-full w-full bg-gradient-to-br from-neutral-700 to-neutral-900"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent"}),e.jsx("span",{onPointerDown:Se,onPointerMove:Ce,onPointerUp:ze,style:{...Oe(r.gallery_card_text_x,r.gallery_card_text_y,{x:0,y:100}),touchAction:"none"},className:`absolute select-none whitespace-nowrap rounded p-3 text-sm font-extrabold text-white transition-colors ${H?"cursor-grabbing bg-white/10 ring-2 ring-brand-400":"cursor-grab hover:bg-white/10"}`,children:g?g.name:"Beispiel-Marke"})]}),e.jsx("p",{className:"mt-1.5 text-center text-xs text-neutral-400",children:"Namen zum Verschieben ziehen"})]}),e.jsxs("div",{className:"flex flex-col gap-3 sm:pt-1",children:[e.jsxs("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:["Position:"," ",e.jsxs("span",{className:"font-mono font-semibold text-neutral-700 dark:text-neutral-200",children:[r.gallery_card_text_x,"% / ",r.gallery_card_text_y,"%"]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl waagerecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_x",0),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Links"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_x",50),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_x",100),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Rechts"})]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"mb-1.5 text-xs font-medium uppercase tracking-wide text-neutral-400",children:"Schnellauswahl senkrecht"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_y",0),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Oben"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_y",50),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Mittig"}),e.jsx("button",{type:"button",onClick:()=>l("gallery_card_text_y",100),className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm text-neutral-600 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-300 dark:hover:bg-neutral-800",children:"Unten"})]})]})]})]})]}),d("google")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google Analytics"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Wird erst geladen, nachdem ein Besucher der Statistik-Kategorie im Cookie-Banner zugestimmt hat. Leer lassen, um Google Analytics zu deaktivieren."}),e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Measurement-ID"}),e.jsx("input",{value:r.ga_measurement_id,onChange:t=>l("ga_measurement_id",t.target.value),placeholder:"G-XXXXXXXXXX",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"})]}),e.jsxs("div",{className:"mt-5 border-t border-neutral-200 pt-5 dark:border-neutral-800",children:[e.jsx("h3",{className:"mb-1 text-sm font-semibold text-neutral-900 dark:text-white",children:"Dashboard-Anbindung (optional)"}),e.jsx("p",{className:"mb-3 text-sm text-neutral-500 dark:text-neutral-400",children:"Zeigt Besucherzahlen direkt in deinem Admin-Dashboard an. Braucht ein Google-Cloud-Service-Account mit Lesezugriff auf diese GA4-Property."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Property-ID"}),e.jsx("input",{value:p,onChange:t=>{T(t.target.value),k(!1)},placeholder:"z. B. 123456789",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Nicht die Measurement-ID (G-...) - zu finden unter GA4 → Verwaltung → Property-Details."})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Service-Account-JSON-Schlüssel ",J?"(leer lassen = unverändert)":""]}),e.jsx("textarea",{rows:4,value:v,onChange:t=>{U(t.target.value),k(!1)},placeholder:J?'{ "type": "service_account", ... } (bereits hinterlegt)':'{ "type": "service_account", ... }',className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 font-mono text-xs dark:border-neutral-700 dark:bg-neutral-900"})]})]}),V&&e.jsx("p",{className:"mt-2 text-sm text-red-600",children:V})]})]}),d("google")&&e.jsxs("section",{className:"rounded-xl border border-neutral-200 bg-white p-6 dark:border-neutral-800 dark:bg-neutral-900",children:[e.jsx("h2",{className:"mb-1 font-semibold text-neutral-900 dark:text-white",children:"Google-Rezensionen"}),e.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Zeigt die echte Google-Bewertung und die aktuellsten Rezensionen auf der Startseite an, statt der fest eingetragenen Beispiel-Texte. Wird einmal täglich automatisch aktualisiert (nie bei einem Seitenbesuch selbst) – die Seite zeigt also immer den letzten erfolgreich abgerufenen Stand."}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:"Place-ID"}),e.jsx("input",{value:h,onChange:t=>{q(t.target.value),f(!1)},placeholder:"z. B. ChIJN1t_tDeuEmsRUsoyG83frY4",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsxs("p",{className:"mt-1 text-xs text-neutral-400",children:["Eindeutige Google-Kennung eures Eintrags – zu finden über den"," ",e.jsx("a",{href:"https://developers.google.com/maps/documentation/places/web-service/place-id#find-id",target:"_blank",rel:"noopener noreferrer",className:"underline hover:text-brand-600",children:"Google Place ID Finder"}),"."]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"mb-1 block text-sm font-medium text-neutral-700 dark:text-neutral-300",children:["Places-API-Key ",j?"(leer lassen = unverändert)":""]}),e.jsx("input",{value:w,onChange:t=>{ee(t.target.value),f(!1)},placeholder:j?"••••••••••••••••••••• (bereits hinterlegt)":"AIzaSy…",className:"w-full rounded-md border border-neutral-300 bg-white px-3 py-2 font-mono text-sm dark:border-neutral-700 dark:bg-neutral-900"}),e.jsx("p",{className:"mt-1 text-xs text-neutral-400",children:"Aus der Google-Cloud-Console, mit aktivierter „Places API (New)“."})]})]}),re&&e.jsx("p",{className:"mt-3 text-sm text-red-600",children:re}),e.jsx("div",{className:"mt-3 flex flex-wrap items-center gap-3",children:e.jsx("button",{type:"button",onClick:Pe,disabled:se||!h||!j,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:se?"Aktualisiere…":"Jetzt aktualisieren"})}),c&&e.jsxs("div",{className:"mt-4 rounded-md bg-neutral-50 p-3 text-sm dark:bg-neutral-800/50",children:[c.rating!=null?e.jsxs("p",{className:"text-neutral-700 dark:text-neutral-300",children:["Aktuell hinterlegt: ",e.jsxs("strong",{children:[c.rating," ★"]})," (",c.rating_count," Bewertungen)",c.updated_at&&e.jsxs(e.Fragment,{children:[" – zuletzt aktualisiert am ",new Date(c.updated_at.replace(" ","T")).toLocaleString("de-DE")]})]}):e.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:"Noch keine erfolgreiche Aktualisierung – die Startseite zeigt bis dahin weiter die Beispiel-Rezensionen."}),c.error&&e.jsxs("p",{className:"mt-1 text-red-600",children:["Letzter Fehler: ",c.error]})]})]}),M&&e.jsx("p",{className:"text-sm text-red-600",children:M}),e.jsx(Te,{dirty:ce,busy:je||De||Ae,savedAt:_e,form:"website-settings-form"})]})}export{et as default}; diff --git a/hifi/assets/eye-Bf2CUjOF.js b/hifi/assets/eye-BXFieSB3.js similarity index 95% rename from hifi/assets/eye-Bf2CUjOF.js rename to hifi/assets/eye-BXFieSB3.js index 0738256..063a9b7 100644 --- a/hifi/assets/eye-Bf2CUjOF.js +++ b/hifi/assets/eye-BXFieSB3.js @@ -1,4 +1,4 @@ -import{G as e}from"./index-Tg8iNBwT.js";/** +import{G as e}from"./index-Cc1wEeIX.js";/** * @license lucide-react v1.23.0 - ISC * * This source code is licensed under the ISC license. diff --git a/hifi/assets/grip-vertical-By7l82Pv.js b/hifi/assets/grip-vertical-0BUKE4NU.js similarity index 91% rename from hifi/assets/grip-vertical-By7l82Pv.js rename to hifi/assets/grip-vertical-0BUKE4NU.js index bf521dd..cb6ab93 100644 --- a/hifi/assets/grip-vertical-By7l82Pv.js +++ b/hifi/assets/grip-vertical-0BUKE4NU.js @@ -1,4 +1,4 @@ -import{G as c}from"./index-Tg8iNBwT.js";/** +import{G as c}from"./index-Cc1wEeIX.js";/** * @license lucide-react v1.23.0 - ISC * * This source code is licensed under the ISC license. diff --git a/hifi/assets/iconRegistry-CE8benTi.js b/hifi/assets/iconRegistry-DrgKxhYw.js similarity index 99% rename from hifi/assets/iconRegistry-CE8benTi.js rename to hifi/assets/iconRegistry-DrgKxhYw.js index 51fb1d6..3942e2a 100644 --- a/hifi/assets/iconRegistry-CE8benTi.js +++ b/hifi/assets/iconRegistry-DrgKxhYw.js @@ -1,4 +1,4 @@ -import{G as e,H as L0,I as x0,J as w0,K as f0,M as I0,s as C0,P as N0,t as b0,Q as $0,C as s,T as q0,U as z0,E as S0,V as A0,W as H0,X as j0,Y as V0,Z as P0,_ as B0,$ as D0,a0 as F0,a1 as R0,a2 as T0,a3 as U0,a4 as O0,a5 as G0,a6 as Z0,a7 as W0,a8 as E0,a9 as X0,aa as K0,ab as fL,ac as IL,ad as CL,j as NL}from"./index-Tg8iNBwT.js";import{D as Q0,a as J0,b as Y0,c as l,F as ea,L as aa,M as ca}from"./music-DPTNgOWL.js";import{a as ta,E as oa}from"./eye-Bf2CUjOF.js";import{G as da}from"./grip-vertical-By7l82Pv.js";import{P as na,R as ha,T as ia}from"./trash-2-CnvKO1vQ.js";/** +import{G as e,H as L0,I as x0,J as w0,K as f0,M as I0,s as C0,P as N0,t as b0,Q as $0,C as s,T as q0,U as z0,E as S0,V as A0,W as H0,X as j0,Y as V0,Z as P0,_ as B0,$ as D0,a0 as F0,a1 as R0,a2 as T0,a3 as U0,a4 as O0,a5 as G0,a6 as Z0,a7 as W0,a8 as E0,a9 as X0,aa as K0,ab as fL,ac as IL,ad as CL,j as NL}from"./index-Cc1wEeIX.js";import{D as Q0,a as J0,b as Y0,c as l,F as ea,L as aa,M as ca}from"./music-B3GiJs_4.js";import{a as ta,E as oa}from"./eye-BXFieSB3.js";import{G as da}from"./grip-vertical-0BUKE4NU.js";import{P as na,R as ha,T as ia}from"./trash-2-UGYx0Sek.js";/** * @license lucide-react v1.23.0 - ISC * * This source code is licensed under the ISC license. diff --git a/hifi/assets/index-Cc1wEeIX.js b/hifi/assets/index-Cc1wEeIX.js new file mode 100644 index 0000000..ac3c124 --- /dev/null +++ b/hifi/assets/index-Cc1wEeIX.js @@ -0,0 +1,268 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/iconRegistry-DrgKxhYw.js","assets/music-B3GiJs_4.js","assets/eye-BXFieSB3.js","assets/grip-vertical-0BUKE4NU.js","assets/trash-2-UGYx0Sek.js","assets/DownloadsPage-CMVi3G0A.js","assets/downloads-B9pqFegV.js","assets/Dashboard-Cqfuh4mJ.js","assets/ImageOptimizer-BWNhyKVh.js","assets/contactRequests-Qfsfq7Lb.js","assets/Brands-CdXOB29N.js","assets/ImageUploadField-DYOhdPMm.js","assets/resizeImage-C6PvAwh0.js","assets/TextStyleWidget-DH0ih_Iq.js","assets/SortableList-DIXFCDYS.js","assets/sortable.esm-D8IvDAze.js","assets/Models-DiJaASky.js","assets/ViewOnSite-CStAY6xT.js","assets/GalleryBrands-7-ErMZO-.js","assets/GalleryProjects-NiVXDHl3.js","assets/GalleryPhotos-CuXZZ7cQ.js","assets/Packages-N3XayAy4.js","assets/Services-BuFoA76N.js","assets/Faqs-Mcg7d29g.js","assets/Partners-B5umAj33.js","assets/Downloads-BM4-wi1i.js","assets/HomeSections-WAiTz48-.js","assets/RichTextEditor-BGWsKoCk.js","assets/SaveBar-Cr-Ys8TW.js","assets/ContactRequests-D4KmPFzX.js","assets/WebsiteSettings-I9lUY-Do.js","assets/LegalSettings-53BO_3BR.js","assets/EmailSettings-Bbg5xyAa.js","assets/DatabaseSettings-CivwQ4EI.js"])))=>i.map(i=>d[i]); +function Lx(e,t){for(var n=0;nr[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();function Wm(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Gm={exports:{}},zo={},Km={exports:{}},q={};/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var Xs=Symbol.for("react.element"),Ax=Symbol.for("react.portal"),Dx=Symbol.for("react.fragment"),Rx=Symbol.for("react.strict_mode"),Ix=Symbol.for("react.profiler"),Vx=Symbol.for("react.provider"),Fx=Symbol.for("react.context"),Ox=Symbol.for("react.forward_ref"),zx=Symbol.for("react.suspense"),Bx=Symbol.for("react.memo"),Hx=Symbol.for("react.lazy"),Nd=Symbol.iterator;function $x(e){return e===null||typeof e!="object"?null:(e=Nd&&e[Nd]||e["@@iterator"],typeof e=="function"?e:null)}var qm={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Ym=Object.assign,Xm={};function zr(e,t,n){this.props=e,this.context=t,this.refs=Xm,this.updater=n||qm}zr.prototype.isReactComponent={};zr.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};zr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Zm(){}Zm.prototype=zr.prototype;function $u(e,t,n){this.props=e,this.context=t,this.refs=Xm,this.updater=n||qm}var Uu=$u.prototype=new Zm;Uu.constructor=$u;Ym(Uu,zr.prototype);Uu.isPureReactComponent=!0;var _d=Array.isArray,Qm=Object.prototype.hasOwnProperty,Wu={current:null},Jm={key:!0,ref:!0,__self:!0,__source:!0};function ep(e,t,n){var r,s={},i=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(i=""+t.key),t)Qm.call(t,r)&&!Jm.hasOwnProperty(r)&&(s[r]=t[r]);var a=arguments.length-2;if(a===1)s.children=n;else if(1>>1,A=N[T];if(0>>1;Ts(de,F))oes(re,de)?(N[T]=re,N[oe]=F,T=oe):(N[T]=de,N[z]=F,T=z);else if(oes(re,F))N[T]=re,N[oe]=F,T=oe;else break e}}return L}function s(N,L){var F=N.sortIndex-L.sortIndex;return F!==0?F:N.id-L.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var u=[],c=[],d=1,f=null,h=3,y=!1,x=!1,w=!1,b=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(N){for(var L=n(c);L!==null;){if(L.callback===null)r(c);else if(L.startTime<=N)r(c),L.sortIndex=L.expirationTime,t(u,L);else break;L=n(c)}}function k(N){if(w=!1,v(N),!x)if(n(u)!==null)x=!0,G(S);else{var L=n(c);L!==null&&X(k,L.startTime-N)}}function S(N,L){x=!1,w&&(w=!1,m(P),P=-1),y=!0;var F=h;try{for(v(L),f=n(u);f!==null&&(!(f.expirationTime>L)||N&&!O());){var T=f.callback;if(typeof T=="function"){f.callback=null,h=f.priorityLevel;var A=T(f.expirationTime<=L);L=e.unstable_now(),typeof A=="function"?f.callback=A:f===n(u)&&r(u),v(L)}else r(u);f=n(u)}if(f!==null)var ie=!0;else{var z=n(c);z!==null&&X(k,z.startTime-L),ie=!1}return ie}finally{f=null,h=F,y=!1}}var C=!1,j=null,P=-1,M=5,E=-1;function O(){return!(e.unstable_now()-EN||125T?(N.sortIndex=F,t(c,N),n(u)===null&&N===n(c)&&(w?(m(P),P=-1):w=!0,X(k,F-T))):(N.sortIndex=A,t(u,N),x||y||(x=!0,G(S))),N},e.unstable_shouldYield=O,e.unstable_wrapCallback=function(N){var L=h;return function(){var F=h;h=L;try{return N.apply(this,arguments)}finally{h=F}}}})(op);ip.exports=op;var tv=ip.exports;/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var nv=p,lt=tv;function _(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ml=Object.prototype.hasOwnProperty,rv=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Ld={},Ad={};function sv(e){return ml.call(Ad,e)?!0:ml.call(Ld,e)?!1:rv.test(e)?Ad[e]=!0:(Ld[e]=!0,!1)}function iv(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function ov(e,t,n,r){if(t===null||typeof t>"u"||iv(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ye(e,t,n,r,s,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var Ve={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ve[e]=new Ye(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ve[t]=new Ye(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ve[e]=new Ye(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ve[e]=new Ye(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ve[e]=new Ye(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ve[e]=new Ye(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ve[e]=new Ye(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ve[e]=new Ye(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ve[e]=new Ye(e,5,!1,e.toLowerCase(),null,!1,!1)});var Ku=/[\-:]([a-z])/g;function qu(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Ku,qu);Ve[t]=new Ye(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Ku,qu);Ve[t]=new Ye(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Ku,qu);Ve[t]=new Ye(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ve[e]=new Ye(e,1,!1,e.toLowerCase(),null,!1,!1)});Ve.xlinkHref=new Ye("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ve[e]=new Ye(e,1,!1,e.toLowerCase(),null,!0,!0)});function Yu(e,t,n,r){var s=Ve.hasOwnProperty(t)?Ve[t]:null;(s!==null?s.type!==0:r||!(2a||s[o]!==i[a]){var u=` +`+s[o].replace(" at new "," at ");return e.displayName&&u.includes("")&&(u=u.replace("",e.displayName)),u}while(1<=o&&0<=a);break}}}finally{ya=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?os(e):""}function av(e){switch(e.tag){case 5:return os(e.type);case 16:return os("Lazy");case 13:return os("Suspense");case 19:return os("SuspenseList");case 0:case 2:case 15:return e=xa(e.type,!1),e;case 11:return e=xa(e.type.render,!1),e;case 1:return e=xa(e.type,!0),e;default:return""}}function xl(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ar:return"Fragment";case or:return"Portal";case pl:return"Profiler";case Xu:return"StrictMode";case gl:return"Suspense";case yl:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case up:return(e.displayName||"Context")+".Consumer";case lp:return(e._context.displayName||"Context")+".Provider";case Zu:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Qu:return t=e.displayName||null,t!==null?t:xl(e.type)||"Memo";case sn:t=e._payload,e=e._init;try{return xl(e(t))}catch{}}return null}function lv(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return xl(t);case 8:return t===Xu?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function jn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function dp(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function uv(e){var t=dp(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var s=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function ci(e){e._valueTracker||(e._valueTracker=uv(e))}function fp(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=dp(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function to(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function vl(e,t){var n=t.checked;return ve({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Rd(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=jn(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function hp(e,t){t=t.checked,t!=null&&Yu(e,"checked",t,!1)}function wl(e,t){hp(e,t);var n=jn(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?kl(e,t.type,n):t.hasOwnProperty("defaultValue")&&kl(e,t.type,jn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Id(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function kl(e,t,n){(t!=="number"||to(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var as=Array.isArray;function br(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s"+t.valueOf().toString()+"",t=di.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Es(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var fs={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},cv=["Webkit","ms","Moz","O"];Object.keys(fs).forEach(function(e){cv.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),fs[t]=fs[e]})});function yp(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||fs.hasOwnProperty(e)&&fs[e]?(""+t).trim():t+"px"}function xp(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=yp(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var dv=ve({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Pl(e,t){if(t){if(dv[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(_(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(_(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(_(61))}if(t.style!=null&&typeof t.style!="object")throw Error(_(62))}}function jl(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Cl=null;function Ju(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Tl=null,Sr=null,Pr=null;function Od(e){if(e=Js(e)){if(typeof Tl!="function")throw Error(_(280));var t=e.stateNode;t&&(t=Wo(t),Tl(e.stateNode,e.type,t))}}function vp(e){Sr?Pr?Pr.push(e):Pr=[e]:Sr=e}function wp(){if(Sr){var e=Sr,t=Pr;if(Pr=Sr=null,Od(e),t)for(e=0;e>>=0,e===0?32:31-(bv(e)/Sv|0)|0}var fi=64,hi=4194304;function ls(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function io(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,i=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~s;a!==0?r=ls(a):(i&=o,i!==0&&(r=ls(i)))}else o=n&~s,o!==0?r=ls(o):i!==0&&(r=ls(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,i=t&-t,s>=i||s===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Zs(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Tt(t),e[t]=n}function Tv(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=ms),qd=" ",Yd=!1;function zp(e,t){switch(e){case"keyup":return t1.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Bp(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var lr=!1;function r1(e,t){switch(e){case"compositionend":return Bp(t);case"keypress":return t.which!==32?null:(Yd=!0,qd);case"textInput":return e=t.data,e===qd&&Yd?null:e;default:return null}}function s1(e,t){if(lr)return e==="compositionend"||!ac&&zp(e,t)?(e=Fp(),Ii=sc=cn=null,lr=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Jd(n)}}function Wp(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Wp(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Gp(){for(var e=window,t=to();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=to(e.document)}return t}function lc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function h1(e){var t=Gp(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Wp(n.ownerDocument.documentElement,n)){if(r!==null&&lc(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var s=n.textContent.length,i=Math.min(r.start,s);r=r.end===void 0?i:Math.min(r.end,s),!e.extend&&i>r&&(s=r,r=i,i=s),s=ef(n,i);var o=ef(n,r);s&&o&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,ur=null,Al=null,gs=null,Dl=!1;function tf(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Dl||ur==null||ur!==to(r)||(r=ur,"selectionStart"in r&&lc(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),gs&&Ds(gs,r)||(gs=r,r=lo(Al,"onSelect"),0fr||(e.current=zl[fr],zl[fr]=null,fr--)}function ue(e,t){fr++,zl[fr]=e.current,e.current=t}var Cn={},$e=Nn(Cn),Qe=Nn(!1),Gn=Cn;function Nr(e,t){var n=e.type.contextTypes;if(!n)return Cn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in n)s[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Je(e){return e=e.childContextTypes,e!=null}function co(){me(Qe),me($e)}function uf(e,t,n){if($e.current!==Cn)throw Error(_(168));ue($e,t),ue(Qe,n)}function tg(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(_(108,lv(e)||"Unknown",s));return ve({},n,r)}function fo(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Cn,Gn=$e.current,ue($e,e),ue(Qe,Qe.current),!0}function cf(e,t,n){var r=e.stateNode;if(!r)throw Error(_(169));n?(e=tg(e,t,Gn),r.__reactInternalMemoizedMergedChildContext=e,me(Qe),me($e),ue($e,e)):me(Qe),ue(Qe,n)}var Ut=null,Go=!1,La=!1;function ng(e){Ut===null?Ut=[e]:Ut.push(e)}function j1(e){Go=!0,ng(e)}function _n(){if(!La&&Ut!==null){La=!0;var e=0,t=ne;try{var n=Ut;for(ne=1;e>=o,s-=o,Wt=1<<32-Tt(t)+s|n<P?(M=j,j=null):M=j.sibling;var E=h(m,j,v[P],k);if(E===null){j===null&&(j=M);break}e&&j&&E.alternate===null&&t(m,j),g=i(E,g,P),C===null?S=E:C.sibling=E,C=E,j=M}if(P===v.length)return n(m,j),pe&&Dn(m,P),S;if(j===null){for(;PP?(M=j,j=null):M=j.sibling;var O=h(m,j,E.value,k);if(O===null){j===null&&(j=M);break}e&&j&&O.alternate===null&&t(m,j),g=i(O,g,P),C===null?S=O:C.sibling=O,C=O,j=M}if(E.done)return n(m,j),pe&&Dn(m,P),S;if(j===null){for(;!E.done;P++,E=v.next())E=f(m,E.value,k),E!==null&&(g=i(E,g,P),C===null?S=E:C.sibling=E,C=E);return pe&&Dn(m,P),S}for(j=r(m,j);!E.done;P++,E=v.next())E=y(j,m,P,E.value,k),E!==null&&(e&&E.alternate!==null&&j.delete(E.key===null?P:E.key),g=i(E,g,P),C===null?S=E:C.sibling=E,C=E);return e&&j.forEach(function(K){return t(m,K)}),pe&&Dn(m,P),S}function b(m,g,v,k){if(typeof v=="object"&&v!==null&&v.type===ar&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case ui:e:{for(var S=v.key,C=g;C!==null;){if(C.key===S){if(S=v.type,S===ar){if(C.tag===7){n(m,C.sibling),g=s(C,v.props.children),g.return=m,m=g;break e}}else if(C.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===sn&&hf(S)===C.type){n(m,C.sibling),g=s(C,v.props),g.ref=ts(m,C,v),g.return=m,m=g;break e}n(m,C);break}else t(m,C);C=C.sibling}v.type===ar?(g=$n(v.props.children,m.mode,k,v.key),g.return=m,m=g):(k=Ui(v.type,v.key,v.props,null,m.mode,k),k.ref=ts(m,g,v),k.return=m,m=k)}return o(m);case or:e:{for(C=v.key;g!==null;){if(g.key===C)if(g.tag===4&&g.stateNode.containerInfo===v.containerInfo&&g.stateNode.implementation===v.implementation){n(m,g.sibling),g=s(g,v.children||[]),g.return=m,m=g;break e}else{n(m,g);break}else t(m,g);g=g.sibling}g=za(v,m.mode,k),g.return=m,m=g}return o(m);case sn:return C=v._init,b(m,g,C(v._payload),k)}if(as(v))return x(m,g,v,k);if(Xr(v))return w(m,g,v,k);wi(m,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,g!==null&&g.tag===6?(n(m,g.sibling),g=s(g,v),g.return=m,m=g):(n(m,g),g=Oa(v,m.mode,k),g.return=m,m=g),o(m)):n(m,g)}return b}var Mr=og(!0),ag=og(!1),po=Nn(null),go=null,pr=null,fc=null;function hc(){fc=pr=go=null}function mc(e){var t=po.current;me(po),e._currentValue=t}function $l(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Cr(e,t){go=e,fc=pr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ze=!0),e.firstContext=null)}function yt(e){var t=e._currentValue;if(fc!==e)if(e={context:e,memoizedValue:t,next:null},pr===null){if(go===null)throw Error(_(308));pr=e,go.dependencies={lanes:0,firstContext:e}}else pr=pr.next=e;return t}var Fn=null;function pc(e){Fn===null?Fn=[e]:Fn.push(e)}function lg(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,pc(t)):(n.next=s.next,s.next=n),t.interleaved=n,Zt(e,r)}function Zt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var on=!1;function gc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function ug(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function qt(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function xn(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,J&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Zt(e,n)}return s=r.interleaved,s===null?(t.next=t,pc(r)):(t.next=s.next,s.next=t),r.interleaved=t,Zt(e,n)}function Fi(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,tc(e,n)}}function mf(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?s=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?s=i=t:i=i.next=t}else s=i=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function yo(e,t,n,r){var s=e.updateQueue;on=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var u=a,c=u.next;u.next=null,o===null?i=c:o.next=c,o=u;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==o&&(a===null?d.firstBaseUpdate=c:a.next=c,d.lastBaseUpdate=u))}if(i!==null){var f=s.baseState;o=0,d=c=u=null,a=i;do{var h=a.lane,y=a.eventTime;if((r&h)===h){d!==null&&(d=d.next={eventTime:y,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var x=e,w=a;switch(h=t,y=n,w.tag){case 1:if(x=w.payload,typeof x=="function"){f=x.call(y,f,h);break e}f=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=w.payload,h=typeof x=="function"?x.call(y,f,h):x,h==null)break e;f=ve({},f,h);break e;case 2:on=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[a]:h.push(a))}else y={eventTime:y,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(c=d=y,u=f):d=d.next=y,o|=h;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;h=a,a=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(!0);if(d===null&&(u=f),s.baseState=u,s.firstBaseUpdate=c,s.lastBaseUpdate=d,t=s.shared.interleaved,t!==null){s=t;do o|=s.lane,s=s.next;while(s!==t)}else i===null&&(s.shared.lanes=0);Yn|=o,e.lanes=o,e.memoizedState=f}}function pf(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Da.transition;Da.transition={};try{e(!1),t()}finally{ne=n,Da.transition=r}}function Cg(){return xt().memoizedState}function N1(e,t,n){var r=wn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Tg(e))Eg(t,n);else if(n=lg(e,t,n,r),n!==null){var s=Ke();Et(n,e,r,s),Ng(n,t,r)}}function _1(e,t,n){var r=wn(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Tg(e))Eg(t,s);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,a=i(o,n);if(s.hasEagerState=!0,s.eagerState=a,_t(a,o)){var u=t.interleaved;u===null?(s.next=s,pc(t)):(s.next=u.next,u.next=s),t.interleaved=s;return}}catch{}finally{}n=lg(e,t,s,r),n!==null&&(s=Ke(),Et(n,e,r,s),Ng(n,t,r))}}function Tg(e){var t=e.alternate;return e===ye||t!==null&&t===ye}function Eg(e,t){ys=vo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ng(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,tc(e,n)}}var wo={readContext:yt,useCallback:Fe,useContext:Fe,useEffect:Fe,useImperativeHandle:Fe,useInsertionEffect:Fe,useLayoutEffect:Fe,useMemo:Fe,useReducer:Fe,useRef:Fe,useState:Fe,useDebugValue:Fe,useDeferredValue:Fe,useTransition:Fe,useMutableSource:Fe,useSyncExternalStore:Fe,useId:Fe,unstable_isNewReconciler:!1},M1={readContext:yt,useCallback:function(e,t){return Dt().memoizedState=[e,t===void 0?null:t],e},useContext:yt,useEffect:yf,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,zi(4194308,4,kg.bind(null,t,e),n)},useLayoutEffect:function(e,t){return zi(4194308,4,e,t)},useInsertionEffect:function(e,t){return zi(4,2,e,t)},useMemo:function(e,t){var n=Dt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Dt();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=N1.bind(null,ye,e),[r.memoizedState,e]},useRef:function(e){var t=Dt();return e={current:e},t.memoizedState=e},useState:gf,useDebugValue:Pc,useDeferredValue:function(e){return Dt().memoizedState=e},useTransition:function(){var e=gf(!1),t=e[0];return e=E1.bind(null,e[1]),Dt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=ye,s=Dt();if(pe){if(n===void 0)throw Error(_(407));n=n()}else{if(n=t(),Ae===null)throw Error(_(349));qn&30||hg(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,yf(pg.bind(null,r,i,e),[e]),r.flags|=2048,Hs(9,mg.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Dt(),t=Ae.identifierPrefix;if(pe){var n=Gt,r=Wt;n=(r&~(1<<32-Tt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=zs++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Vt]=t,e[Vs]=r,Og(e,t,!1,!1),t.stateNode=e;e:{switch(o=jl(n,r),n){case"dialog":he("cancel",e),he("close",e),s=r;break;case"iframe":case"object":case"embed":he("load",e),s=r;break;case"video":case"audio":for(s=0;sDr&&(t.flags|=128,r=!0,ns(i,!1),t.lanes=4194304)}else{if(!r)if(e=xo(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ns(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!pe)return Oe(t),null}else 2*Pe()-i.renderingStartTime>Dr&&n!==1073741824&&(t.flags|=128,r=!0,ns(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(n=i.last,n!==null?n.sibling=o:t.child=o,i.last=o)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Pe(),t.sibling=null,n=ge.current,ue(ge,r?n&1|2:n&1),t):(Oe(t),null);case 22:case 23:return _c(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?st&1073741824&&(Oe(t),t.subtreeFlags&6&&(t.flags|=8192)):Oe(t),null;case 24:return null;case 25:return null}throw Error(_(156,t.tag))}function O1(e,t){switch(cc(t),t.tag){case 1:return Je(t.type)&&co(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Lr(),me(Qe),me($e),vc(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return xc(t),null;case 13:if(me(ge),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(_(340));_r()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return me(ge),null;case 4:return Lr(),null;case 10:return mc(t.type._context),null;case 22:case 23:return _c(),null;case 24:return null;default:return null}}var bi=!1,He=!1,z1=typeof WeakSet=="function"?WeakSet:Set,D=null;function gr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){be(e,t,r)}else n.current=null}function Ql(e,t,n){try{n()}catch(r){be(e,t,r)}}var Ef=!1;function B1(e,t){if(Rl=oo,e=Gp(),lc(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var s=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,a=-1,u=-1,c=0,d=0,f=e,h=null;t:for(;;){for(var y;f!==n||s!==0&&f.nodeType!==3||(a=o+s),f!==i||r!==0&&f.nodeType!==3||(u=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(y=f.firstChild)!==null;)h=f,f=y;for(;;){if(f===e)break t;if(h===n&&++c===s&&(a=o),h===i&&++d===r&&(u=o),(y=f.nextSibling)!==null)break;f=h,h=f.parentNode}f=y}n=a===-1||u===-1?null:{start:a,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(Il={focusedElem:e,selectionRange:n},oo=!1,D=t;D!==null;)if(t=D,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,D=e;else for(;D!==null;){t=D;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var w=x.memoizedProps,b=x.memoizedState,m=t.stateNode,g=m.getSnapshotBeforeUpdate(t.elementType===t.type?w:St(t.type,w),b);m.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(_(163))}}catch(k){be(t,t.return,k)}if(e=t.sibling,e!==null){e.return=t.return,D=e;break}D=t.return}return x=Ef,Ef=!1,x}function xs(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var i=s.destroy;s.destroy=void 0,i!==void 0&&Ql(t,n,i)}s=s.next}while(s!==r)}}function Yo(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Jl(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Hg(e){var t=e.alternate;t!==null&&(e.alternate=null,Hg(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Vt],delete t[Vs],delete t[Ol],delete t[S1],delete t[P1])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function $g(e){return e.tag===5||e.tag===3||e.tag===4}function Nf(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||$g(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function eu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=uo));else if(r!==4&&(e=e.child,e!==null))for(eu(e,t,n),e=e.sibling;e!==null;)eu(e,t,n),e=e.sibling}function tu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(tu(e,t,n),e=e.sibling;e!==null;)tu(e,t,n),e=e.sibling}var Re=null,Pt=!1;function nn(e,t,n){for(n=n.child;n!==null;)Ug(e,t,n),n=n.sibling}function Ug(e,t,n){if(Ft&&typeof Ft.onCommitFiberUnmount=="function")try{Ft.onCommitFiberUnmount(Bo,n)}catch{}switch(n.tag){case 5:He||gr(n,t);case 6:var r=Re,s=Pt;Re=null,nn(e,t,n),Re=r,Pt=s,Re!==null&&(Pt?(e=Re,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Re.removeChild(n.stateNode));break;case 18:Re!==null&&(Pt?(e=Re,n=n.stateNode,e.nodeType===8?Ma(e.parentNode,n):e.nodeType===1&&Ma(e,n),Ls(e)):Ma(Re,n.stateNode));break;case 4:r=Re,s=Pt,Re=n.stateNode.containerInfo,Pt=!0,nn(e,t,n),Re=r,Pt=s;break;case 0:case 11:case 14:case 15:if(!He&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&Ql(n,t,o),s=s.next}while(s!==r)}nn(e,t,n);break;case 1:if(!He&&(gr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){be(n,t,a)}nn(e,t,n);break;case 21:nn(e,t,n);break;case 22:n.mode&1?(He=(r=He)||n.memoizedState!==null,nn(e,t,n),He=r):nn(e,t,n);break;default:nn(e,t,n)}}function _f(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new z1),t.forEach(function(r){var s=X1.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function wt(e,t){var n=t.deletions;if(n!==null)for(var r=0;rs&&(s=o),r&=~i}if(r=s,r=Pe()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*$1(r/1960))-r,10e?16:e,dn===null)var r=!1;else{if(e=dn,dn=null,So=0,J&6)throw Error(_(331));var s=J;for(J|=4,D=e.current;D!==null;){var i=D,o=i.child;if(D.flags&16){var a=i.deletions;if(a!==null){for(var u=0;uPe()-Ec?Hn(e,0):Tc|=n),et(e,t)}function Qg(e,t){t===0&&(e.mode&1?(t=hi,hi<<=1,!(hi&130023424)&&(hi=4194304)):t=1);var n=Ke();e=Zt(e,t),e!==null&&(Zs(e,t,n),et(e,n))}function Y1(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Qg(e,n)}function X1(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(_(314))}r!==null&&r.delete(t),Qg(e,n)}var Jg;Jg=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Qe.current)Ze=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Ze=!1,V1(e,t,n);Ze=!!(e.flags&131072)}else Ze=!1,pe&&t.flags&1048576&&rg(t,mo,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Bi(e,t),e=t.pendingProps;var s=Nr(t,$e.current);Cr(t,n),s=kc(null,t,r,e,s,n);var i=bc();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Je(r)?(i=!0,fo(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,gc(t),s.updater=qo,t.stateNode=s,s._reactInternals=t,Wl(t,r,e,n),t=ql(null,t,r,!0,i,n)):(t.tag=0,pe&&i&&uc(t),Ue(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Bi(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=Q1(r),e=St(r,e),s){case 0:t=Kl(null,t,r,e,n);break e;case 1:t=jf(null,t,r,e,n);break e;case 11:t=Sf(null,t,r,e,n);break e;case 14:t=Pf(null,t,r,St(r.type,e),n);break e}throw Error(_(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),Kl(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),jf(e,t,r,s,n);case 3:e:{if(Ig(t),e===null)throw Error(_(387));r=t.pendingProps,i=t.memoizedState,s=i.element,ug(e,t),yo(t,r,null,n);var o=t.memoizedState;if(r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){s=Ar(Error(_(423)),t),t=Cf(e,t,r,n,s);break e}else if(r!==s){s=Ar(Error(_(424)),t),t=Cf(e,t,r,n,s);break e}else for(it=yn(t.stateNode.containerInfo.firstChild),ot=t,pe=!0,jt=null,n=ag(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(_r(),r===s){t=Qt(e,t,n);break e}Ue(e,t,r,n)}t=t.child}return t;case 5:return cg(t),e===null&&Hl(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,Vl(r,s)?o=null:i!==null&&Vl(r,i)&&(t.flags|=32),Rg(e,t),Ue(e,t,o,n),t.child;case 6:return e===null&&Hl(t),null;case 13:return Vg(e,t,n);case 4:return yc(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Mr(t,null,r,n):Ue(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),Sf(e,t,r,s,n);case 7:return Ue(e,t,t.pendingProps,n),t.child;case 8:return Ue(e,t,t.pendingProps.children,n),t.child;case 12:return Ue(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,i=t.memoizedProps,o=s.value,ue(po,r._currentValue),r._currentValue=o,i!==null)if(_t(i.value,o)){if(i.children===s.children&&!Qe.current){t=Qt(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){o=i.child;for(var u=a.firstContext;u!==null;){if(u.context===r){if(i.tag===1){u=qt(-1,n&-n),u.tag=2;var c=i.updateQueue;if(c!==null){c=c.shared;var d=c.pending;d===null?u.next=u:(u.next=d.next,d.next=u),c.pending=u}}i.lanes|=n,u=i.alternate,u!==null&&(u.lanes|=n),$l(i.return,n,t),a.lanes|=n;break}u=u.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(_(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),$l(o,n,t),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===t){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}Ue(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,Cr(t,n),s=yt(s),r=r(s),t.flags|=1,Ue(e,t,r,n),t.child;case 14:return r=t.type,s=St(r,t.pendingProps),s=St(r.type,s),Pf(e,t,r,s,n);case 15:return Ag(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),Bi(e,t),t.tag=1,Je(r)?(e=!0,fo(t)):e=!1,Cr(t,n),_g(t,r,s),Wl(t,r,s,n),ql(null,t,r,!0,e,n);case 19:return Fg(e,t,n);case 22:return Dg(e,t,n)}throw Error(_(156,t.tag))};function e0(e,t){return Tp(e,t)}function Z1(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function mt(e,t,n,r){return new Z1(e,t,n,r)}function Lc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Q1(e){if(typeof e=="function")return Lc(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Zu)return 11;if(e===Qu)return 14}return 2}function kn(e,t){var n=e.alternate;return n===null?(n=mt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Ui(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")Lc(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case ar:return $n(n.children,s,i,t);case Xu:o=8,s|=8;break;case pl:return e=mt(12,n,t,s|2),e.elementType=pl,e.lanes=i,e;case gl:return e=mt(13,n,t,s),e.elementType=gl,e.lanes=i,e;case yl:return e=mt(19,n,t,s),e.elementType=yl,e.lanes=i,e;case cp:return Zo(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case lp:o=10;break e;case up:o=9;break e;case Zu:o=11;break e;case Qu:o=14;break e;case sn:o=16,r=null;break e}throw Error(_(130,e==null?e:typeof e,""))}return t=mt(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function $n(e,t,n,r){return e=mt(7,e,r,t),e.lanes=n,e}function Zo(e,t,n,r){return e=mt(22,e,r,t),e.elementType=cp,e.lanes=n,e.stateNode={isHidden:!1},e}function Oa(e,t,n){return e=mt(6,e,null,t),e.lanes=n,e}function za(e,t,n){return t=mt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function J1(e,t,n,r,s){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=wa(0),this.expirationTimes=wa(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=wa(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Ac(e,t,n,r,s,i,o,a,u){return e=new J1(e,t,n,a,u),t===1?(t=1,i===!0&&(t|=8)):t=0,i=mt(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},gc(i),e}function ew(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(s0)}catch(e){console.error(e)}}s0(),sp.exports=ut;var Vc=sp.exports;const EN=Wm(Vc);var Ff=Vc;hl.createRoot=Ff.createRoot,hl.hydrateRoot=Ff.hydrateRoot;/** + * @remix-run/router v1.23.3 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Us(){return Us=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function Fc(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function ow(){return Math.random().toString(36).substr(2,8)}function zf(e,t){return{usr:e.state,key:e.key,idx:t}}function ou(e,t,n,r){return n===void 0&&(n=null),Us({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?$r(t):t,{state:n,key:t&&t.key||r||ow()})}function Co(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function $r(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function aw(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,a=fn.Pop,u=null,c=d();c==null&&(c=0,o.replaceState(Us({},o.state,{idx:c}),""));function d(){return(o.state||{idx:null}).idx}function f(){a=fn.Pop;let b=d(),m=b==null?null:b-c;c=b,u&&u({action:a,location:w.location,delta:m})}function h(b,m){a=fn.Push;let g=ou(w.location,b,m);c=d()+1;let v=zf(g,c),k=w.createHref(g);try{o.pushState(v,"",k)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;s.location.assign(k)}i&&u&&u({action:a,location:w.location,delta:1})}function y(b,m){a=fn.Replace;let g=ou(w.location,b,m);c=d();let v=zf(g,c),k=w.createHref(g);o.replaceState(v,"",k),i&&u&&u({action:a,location:w.location,delta:0})}function x(b){let m=s.location.origin!=="null"?s.location.origin:s.location.href,g=typeof b=="string"?b:Co(b);return g=g.replace(/ $/,"%20"),xe(m,"No window.location.(origin|href) available to create URL for href: "+g),new URL(g,m)}let w={get action(){return a},get location(){return e(s,o)},listen(b){if(u)throw new Error("A history only accepts one active listener");return s.addEventListener(Of,f),u=b,()=>{s.removeEventListener(Of,f),u=null}},createHref(b){return t(s,b)},createURL:x,encodeLocation(b){let m=x(b);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:h,replace:y,go(b){return o.go(b)}};return w}var Bf;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Bf||(Bf={}));function lw(e,t,n){return n===void 0&&(n="/"),uw(e,t,n)}function uw(e,t,n,r){let s=typeof t=="string"?$r(t):t,i=Rr(s.pathname||"/",n);if(i==null)return null;let o=i0(e);cw(o);let a=null,u=kw(i);for(let c=0;a==null&&c{let u={relativePath:a===void 0?i.path||"":a,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};u.relativePath.startsWith("/")&&(xe(u.relativePath.startsWith(r),'Absolute route path "'+u.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),u.relativePath=u.relativePath.slice(r.length));let c=bn([r,u.relativePath]),d=n.concat(u);i.children&&i.children.length>0&&(xe(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),i0(i.children,t,d,c)),!(i.path==null&&!i.index)&&t.push({path:c,score:yw(c,i.index),routesMeta:d})};return e.forEach((i,o)=>{var a;if(i.path===""||!((a=i.path)!=null&&a.includes("?")))s(i,o);else for(let u of o0(i.path))s(i,o,u)}),t}function o0(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return s?[i,""]:[i];let o=o0(r.join("/")),a=[];return a.push(...o.map(u=>u===""?i:[i,u].join("/"))),s&&a.push(...o),a.map(u=>e.startsWith("/")&&u===""?"/":u)}function cw(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:xw(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const dw=/^:[\w-]+$/,fw=3,hw=2,mw=1,pw=10,gw=-2,Hf=e=>e==="*";function yw(e,t){let n=e.split("/"),r=n.length;return n.some(Hf)&&(r+=gw),t&&(r+=hw),n.filter(s=>!Hf(s)).reduce((s,i)=>s+(dw.test(i)?fw:i===""?mw:pw),r)}function xw(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function vw(e,t,n){let{routesMeta:r}=e,s={},i="/",o=[];for(let a=0;a{let{paramName:h,isOptional:y}=d;if(h==="*"){let w=a[f]||"";o=i.slice(0,i.length-w.length).replace(/(.)\/+$/,"$1")}const x=a[f];return y&&!x?c[h]=void 0:c[h]=(x||"").replace(/%2F/g,"/"),c},{}),pathname:i,pathnameBase:o,pattern:e}}function ww(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Fc(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,u)=>(r.push({paramName:a,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function kw(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Fc(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Rr(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}const bw=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Sw=e=>bw.test(e);function Pw(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?$r(e):e,i;if(n)if(Sw(n))i=n;else{if(n.includes("//")){let o=n;n=a0(n),Fc(!1,"Pathnames cannot have embedded double slashes - normalizing "+(o+" -> "+n))}n.startsWith("/")?i=$f(n.substring(1),"/"):i=$f(n,t)}else i=t;return{pathname:i,search:Tw(r),hash:Ew(s)}}function $f(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function Ba(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function jw(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Oc(e,t){let n=jw(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function zc(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=$r(e):(s=Us({},e),xe(!s.pathname||!s.pathname.includes("?"),Ba("?","pathname","search",s)),xe(!s.pathname||!s.pathname.includes("#"),Ba("#","pathname","hash",s)),xe(!s.search||!s.search.includes("#"),Ba("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),f-=1;s.pathname=h.join("/")}a=f>=0?t[f]:"/"}let u=Pw(s,a),c=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(c||d)&&(u.pathname+="/"),u}const a0=e=>e.replace(/\/\/+/g,"/"),bn=e=>a0(e.join("/")),Cw=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Tw=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Ew=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function Nw(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const l0=["post","put","patch","delete"];new Set(l0);const _w=["get",...l0];new Set(_w);/** + * React Router v6.30.4 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Ws(){return Ws=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),p.useCallback(function(c,d){if(d===void 0&&(d={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let f=zc(c,JSON.parse(o),i,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:bn([t,f.pathname])),(d.replace?r.replace:r.push)(f,d.state,d)},[t,r,o,i,e])}const Aw=p.createContext(null);function Dw(e){let t=p.useContext(Bt).outlet;return t&&p.createElement(Aw.Provider,{value:e},t)}function Bc(){let{matches:e}=p.useContext(Bt),t=e[e.length-1];return t?t.params:{}}function ia(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=p.useContext(tn),{matches:s}=p.useContext(Bt),{pathname:i}=nt(),o=JSON.stringify(Oc(s,r.v7_relativeSplatPath));return p.useMemo(()=>zc(e,JSON.parse(o),i,n==="path"),[e,o,i,n])}function Rw(e,t){return Iw(e,t)}function Iw(e,t,n,r){Ur()||xe(!1);let{navigator:s}=p.useContext(tn),{matches:i}=p.useContext(Bt),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let c=nt(),d;if(t){var f;let b=typeof t=="string"?$r(t):t;u==="/"||(f=b.pathname)!=null&&f.startsWith(u)||xe(!1),d=b}else d=c;let h=d.pathname||"/",y=h;if(u!=="/"){let b=u.replace(/^\//,"").split("/");y="/"+h.replace(/^\//,"").split("/").slice(b.length).join("/")}let x=lw(e,{pathname:y}),w=Bw(x&&x.map(b=>Object.assign({},b,{params:Object.assign({},a,b.params),pathname:bn([u,s.encodeLocation?s.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?u:bn([u,s.encodeLocation?s.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),i,n,r);return t&&w?p.createElement(ra.Provider,{value:{location:Ws({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:fn.Pop}},w):w}function Vw(){let e=Ww(),t=Nw(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return p.createElement(p.Fragment,null,p.createElement("h2",null,"Unexpected Application Error!"),p.createElement("h3",{style:{fontStyle:"italic"}},t),n?p.createElement("pre",{style:s},n):null,null)}const Fw=p.createElement(Vw,null);class Ow extends p.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?p.createElement(Bt.Provider,{value:this.props.routeContext},p.createElement(c0.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function zw(e){let{routeContext:t,match:n,children:r}=e,s=p.useContext(na);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),p.createElement(Bt.Provider,{value:t},r)}function Bw(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let d=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id])!==void 0);d>=0||xe(!1),o=o.slice(0,Math.min(o.length,d+1))}let u=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((d,f,h)=>{let y,x=!1,w=null,b=null;n&&(y=a&&f.route.id?a[f.route.id]:void 0,w=f.route.errorElement||Fw,u&&(c<0&&h===0?(Kw("route-fallback"),x=!0,b=null):c===h&&(x=!0,b=f.route.hydrateFallbackElement||null)));let m=t.concat(o.slice(0,h+1)),g=()=>{let v;return y?v=w:x?v=b:f.route.Component?v=p.createElement(f.route.Component,null):f.route.element?v=f.route.element:v=d,p.createElement(zw,{match:f,routeContext:{outlet:d,matches:m,isDataRoute:n!=null},children:v})};return n&&(f.route.ErrorBoundary||f.route.errorElement||h===0)?p.createElement(Ow,{location:n.location,revalidation:n.revalidation,component:w,error:y,children:g(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):g()},null)}var f0=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(f0||{}),h0=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(h0||{});function Hw(e){let t=p.useContext(na);return t||xe(!1),t}function $w(e){let t=p.useContext(u0);return t||xe(!1),t}function Uw(e){let t=p.useContext(Bt);return t||xe(!1),t}function m0(e){let t=Uw(),n=t.matches[t.matches.length-1];return n.route.id||xe(!1),n.route.id}function Ww(){var e;let t=p.useContext(c0),n=$w(),r=m0();return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function Gw(){let{router:e}=Hw(f0.UseNavigateStable),t=m0(h0.UseNavigateStable),n=p.useRef(!1);return d0(()=>{n.current=!0}),p.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Ws({fromRouteId:t},i)))},[e,t])}const Uf={};function Kw(e,t,n){Uf[e]||(Uf[e]=!0)}function qw(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function Zn(e){let{to:t,replace:n,state:r,relative:s}=e;Ur()||xe(!1);let{future:i,static:o}=p.useContext(tn),{matches:a}=p.useContext(Bt),{pathname:u}=nt(),c=sa(),d=zc(t,Oc(a,i.v7_relativeSplatPath),u,s==="path"),f=JSON.stringify(d);return p.useEffect(()=>c(JSON.parse(f),{replace:n,state:r,relative:s}),[c,f,s,n,r]),null}function Hc(e){return Dw(e.context)}function B(e){xe(!1)}function Yw(e){let{basename:t="/",children:n=null,location:r,navigationType:s=fn.Pop,navigator:i,static:o=!1,future:a}=e;Ur()&&xe(!1);let u=t.replace(/^\/*/,"/"),c=p.useMemo(()=>({basename:u,navigator:i,static:o,future:Ws({v7_relativeSplatPath:!1},a)}),[u,a,i,o]);typeof r=="string"&&(r=$r(r));let{pathname:d="/",search:f="",hash:h="",state:y=null,key:x="default"}=r,w=p.useMemo(()=>{let b=Rr(d,u);return b==null?null:{location:{pathname:b,search:f,hash:h,state:y,key:x},navigationType:s}},[u,d,f,h,y,x,s]);return w==null?null:p.createElement(tn.Provider,{value:c},p.createElement(ra.Provider,{children:n,value:w}))}function Xw(e){let{children:t,location:n}=e;return Rw(lu(t),n)}new Promise(()=>{});function lu(e,t){t===void 0&&(t=[]);let n=[];return p.Children.forEach(e,(r,s)=>{if(!p.isValidElement(r))return;let i=[...t,s];if(r.type===p.Fragment){n.push.apply(n,lu(r.props.children,i));return}r.type!==B&&xe(!1),!r.props.index||!r.props.children||xe(!1);let o={id:r.props.id||i.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=lu(r.props.children,i)),n.push(o)}),n}/** + * React Router DOM v6.30.4 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function To(){return To=Object.assign?Object.assign.bind():function(e){for(var t=1;t{let r=e[n];return t.concat(Array.isArray(r)?r.map(s=>[n,s]):[[n,r]])},[]))}function Jw(e,t){let n=uu(e);return t&&t.forEach((r,s)=>{n.has(s)||t.getAll(s).forEach(i=>{n.append(s,i)})}),n}const ek=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],tk=["aria-current","caseSensitive","className","end","style","to","viewTransition","children"],nk="6";try{window.__reactRouterVersion=nk}catch{}const rk=p.createContext({isTransitioning:!1}),sk="startTransition",Wf=qx[sk];function ik(e){let{basename:t,children:n,future:r,window:s}=e,i=p.useRef();i.current==null&&(i.current=iw({window:s,v5Compat:!0}));let o=i.current,[a,u]=p.useState({action:o.action,location:o.location}),{v7_startTransition:c}=r||{},d=p.useCallback(f=>{c&&Wf?Wf(()=>u(f)):u(f)},[u,c]);return p.useLayoutEffect(()=>o.listen(d),[o,d]),p.useEffect(()=>qw(r),[r]),p.createElement(Yw,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}const ok=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",ak=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,W=p.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:i,replace:o,state:a,target:u,to:c,preventScrollReset:d,viewTransition:f}=t,h=p0(t,ek),{basename:y}=p.useContext(tn),x,w=!1;if(typeof c=="string"&&ak.test(c)&&(x=c,ok))try{let v=new URL(window.location.href),k=c.startsWith("//")?new URL(v.protocol+c):new URL(c),S=Rr(k.pathname,y);k.origin===v.origin&&S!=null?c=S+k.search+k.hash:w=!0}catch{}let b=Mw(c,{relative:s}),m=ck(c,{replace:o,state:a,target:u,preventScrollReset:d,relative:s,viewTransition:f});function g(v){r&&r(v),v.defaultPrevented||m(v)}return p.createElement("a",To({},h,{href:x||b,onClick:w||i?r:g,ref:n,target:u}))}),lk=p.forwardRef(function(t,n){let{"aria-current":r="page",caseSensitive:s=!1,className:i="",end:o=!1,style:a,to:u,viewTransition:c,children:d}=t,f=p0(t,tk),h=ia(u,{relative:f.relative}),y=nt(),x=p.useContext(u0),{navigator:w,basename:b}=p.useContext(tn),m=x!=null&&fk(h)&&c===!0,g=w.encodeLocation?w.encodeLocation(h).pathname:h.pathname,v=y.pathname,k=x&&x.navigation&&x.navigation.location?x.navigation.location.pathname:null;s||(v=v.toLowerCase(),k=k?k.toLowerCase():null,g=g.toLowerCase()),k&&b&&(k=Rr(k,b)||k);const S=g!=="/"&&g.endsWith("/")?g.length-1:g.length;let C=v===g||!o&&v.startsWith(g)&&v.charAt(S)==="/",j=k!=null&&(k===g||!o&&k.startsWith(g)&&k.charAt(g.length)==="/"),P={isActive:C,isPending:j,isTransitioning:m},M=C?r:void 0,E;typeof i=="function"?E=i(P):E=[i,C?"active":null,j?"pending":null,m?"transitioning":null].filter(Boolean).join(" ");let O=typeof a=="function"?a(P):a;return p.createElement(W,To({},f,{"aria-current":M,className:E,ref:n,style:O,to:u,viewTransition:c}),typeof d=="function"?d(P):d)});var cu;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(cu||(cu={}));var Gf;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Gf||(Gf={}));function uk(e){let t=p.useContext(na);return t||xe(!1),t}function ck(e,t){let{target:n,replace:r,state:s,preventScrollReset:i,relative:o,viewTransition:a}=t===void 0?{}:t,u=sa(),c=nt(),d=ia(e,{relative:o});return p.useCallback(f=>{if(Qw(f,n)){f.preventDefault();let h=r!==void 0?r:Co(c)===Co(d);u(e,{replace:h,state:s,preventScrollReset:i,relative:o,viewTransition:a})}},[c,u,d,r,s,n,e,i,o,a])}function dk(e){let t=p.useRef(uu(e)),n=p.useRef(!1),r=nt(),s=p.useMemo(()=>Jw(r.search,n.current?null:t.current),[r.search]),i=sa(),o=p.useCallback((a,u)=>{const c=uu(typeof a=="function"?a(s):a);n.current=!0,i("?"+c,u)},[i,s]);return[s,o]}function fk(e,t){t===void 0&&(t={});let n=p.useContext(rk);n==null&&xe(!1);let{basename:r}=uk(cu.useViewTransitionState),s=ia(e,{relative:t.relative});if(!n.isTransitioning)return!1;let i=Rr(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=Rr(n.nextLocation.pathname,r)||n.nextLocation.pathname;return au(s.pathname,o)!=null||au(s.pathname,i)!=null}const hk="modulepreload",mk=function(e){return"/"+e},Kf={},Y=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),a=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));s=Promise.allSettled(n.map(u=>{if(u=mk(u),u in Kf)return;Kf[u]=!0;const c=u.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${u}"]${d}`))return;const f=document.createElement("link");if(f.rel=c?"stylesheet":hk,c||(f.as="script"),f.crossOrigin="",f.href=u,a&&f.setAttribute("nonce",a),document.head.appendChild(f),c)return new Promise((h,y)=>{f.addEventListener("load",h),f.addEventListener("error",()=>y(new Error(`Unable to preload CSS for ${u}`)))})}))}function i(o){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o}return s.then(o=>{for(const a of o||[])a.status==="rejected"&&i(a.reason);return t().catch(i)})},$c=p.createContext({});function Jt(e){const t=p.useRef(null);return t.current===null&&(t.current=e()),t.current}const pk=typeof window<"u",ti=pk?p.useLayoutEffect:p.useEffect,oa=p.createContext(null);function Uc(e,t){e.indexOf(t)===-1&&e.push(t)}function Eo(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Mt=(e,t,n)=>n>t?t:n{};const Tn={},g0=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),y0=e=>typeof e=="object"&&e!==null,x0=e=>/^0[^.\s]+$/u.test(e);function v0(e){let t;return()=>(t===void 0&&(t=e()),t)}const tt=e=>e,ni=(...e)=>e.reduce((t,n)=>r=>n(t(r))),Ir=(e,t,n)=>{const r=t-e;return r?(n-e)/r:1};class Gc{constructor(){this.subscriptions=[]}add(t){return Uc(this.subscriptions,t),()=>Eo(this.subscriptions,t)}notify(t,n,r){const s=this.subscriptions.length;if(s)if(s===1)this.subscriptions[0](t,n,r);else for(let i=0;ie*1e3,pt=e=>e/1e3,Kc=(e,t)=>t?e*(1e3/t):0,w0=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,gk=1e-7,yk=12;function xk(e,t,n,r,s){let i,o,a=0;do o=t+(n-t)/2,i=w0(o,r,s)-e,i>0?n=o:t=o;while(Math.abs(i)>gk&&++axk(i,0,1,e,n);return i=>i===0||i===1?i:w0(s(i),t,r)}const k0=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,b0=e=>t=>1-e(1-t),S0=ri(.33,1.53,.69,.99),qc=b0(S0),P0=k0(qc),j0=e=>e>=1?1:(e*=2)<1?.5*qc(e):.5*(2-Math.pow(2,-10*(e-1))),Yc=e=>1-Math.sin(Math.acos(e)),C0=b0(Yc),T0=k0(Yc),vk=ri(.42,0,1,1),wk=ri(0,0,.58,1),E0=ri(.42,0,.58,1),kk=e=>Array.isArray(e)&&typeof e[0]!="number",N0=e=>Array.isArray(e)&&typeof e[0]=="number",bk={linear:tt,easeIn:vk,easeInOut:E0,easeOut:wk,circIn:Yc,circInOut:T0,circOut:C0,backIn:qc,backInOut:P0,backOut:S0,anticipate:j0},Sk=e=>typeof e=="string",qf=e=>{if(N0(e)){Wc(e.length===4);const[t,n,r,s]=e;return ri(t,n,r,s)}else if(Sk(e))return bk[e];return e},ji=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Pk(e){let t=new Set,n=new Set,r=!1,s=!1;const i=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function a(c){i.has(c)&&(u.schedule(c),e()),c(o)}const u={schedule:(c,d=!1,f=!1)=>{const y=f&&r?t:n;return d&&i.add(c),y.add(c),c},cancel:c=>{n.delete(c),i.delete(c)},process:c=>{if(o=c,r){s=!0;return}r=!0;const d=t;t=n,n=d,t.forEach(a),t.clear(),r=!1,s&&(s=!1,u.process(c))}};return u}const jk=40;function _0(e,t){let n=!1,r=!0;const s={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,o=ji.reduce((v,k)=>(v[k]=Pk(i),v),{}),{setup:a,read:u,resolveKeyframes:c,preUpdate:d,update:f,preRender:h,render:y,postRender:x}=o,w=()=>{const v=Tn.useManualTiming,k=v?s.timestamp:performance.now();n=!1,v||(s.delta=r?1e3/60:Math.max(Math.min(k-s.timestamp,jk),1)),s.timestamp=k,s.isProcessing=!0,a.process(s),u.process(s),c.process(s),d.process(s),f.process(s),h.process(s),y.process(s),x.process(s),s.isProcessing=!1,n&&t&&(r=!1,e(w))},b=()=>{n=!0,r=!0,s.isProcessing||e(w)};return{schedule:ji.reduce((v,k)=>{const S=o[k];return v[k]=(C,j=!1,P=!1)=>(n||b(),S.schedule(C,j,P)),v},{}),cancel:v=>{for(let k=0;k(Wi===void 0&&We.set(Me.isProcessing||Tn.useManualTiming?Me.timestamp:performance.now()),Wi),set:e=>{Wi=e,queueMicrotask(Ck)}},M0=e=>t=>typeof t=="string"&&t.startsWith(e),L0=M0("--"),Tk=M0("var(--"),Xc=e=>Tk(e)?Ek.test(e.split("/*")[0].trim()):!1,Ek=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Yf(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const Wr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Gs={...Wr,transform:e=>Mt(0,1,e)},Ci={...Wr,default:1},ks=e=>Math.round(e*1e5)/1e5,Zc=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Nk(e){return e==null}const _k=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Qc=(e,t)=>n=>!!(typeof n=="string"&&_k.test(n)&&n.startsWith(e)||t&&!Nk(n)&&Object.prototype.hasOwnProperty.call(n,t)),A0=(e,t,n)=>r=>{if(typeof r!="string")return r;const[s,i,o,a]=r.match(Zc);return{[e]:parseFloat(s),[t]:parseFloat(i),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},Mk=e=>Mt(0,255,e),$a={...Wr,transform:e=>Math.round(Mk(e))},zn={test:Qc("rgb","red"),parse:A0("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+$a.transform(e)+", "+$a.transform(t)+", "+$a.transform(n)+", "+ks(Gs.transform(r))+")"};function Lk(e){let t="",n="",r="",s="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),s=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),s=e.substring(4,5),t+=t,n+=n,r+=r,s+=s),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:s?parseInt(s,16)/255:1}}const du={test:Qc("#"),parse:Lk,transform:zn.transform},si=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Ht=si("deg"),zt=si("%"),R=si("px"),Ak=si("vh"),Dk=si("vw"),Xf={...zt,parse:e=>zt.parse(e)/100,transform:e=>zt.transform(e*100)},xr={test:Qc("hsl","hue"),parse:A0("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+zt.transform(ks(t))+", "+zt.transform(ks(n))+", "+ks(Gs.transform(r))+")"},je={test:e=>zn.test(e)||du.test(e)||xr.test(e),parse:e=>zn.test(e)?zn.parse(e):xr.test(e)?xr.parse(e):du.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?zn.transform(e):xr.transform(e),getAnimatableNone:e=>{const t=je.parse(e);return t.alpha=0,je.transform(t)}},Rk=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Ik(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Zc))==null?void 0:t.length)||0)+(((n=e.match(Rk))==null?void 0:n.length)||0)>0}const D0="number",R0="color",Vk="var",Fk="var(",Zf="${}",Ok=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Vr(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},s=[];let i=0;const a=t.replace(Ok,u=>(je.test(u)?(r.color.push(i),s.push(R0),n.push(je.parse(u))):u.startsWith(Fk)?(r.var.push(i),s.push(Vk),n.push(u)):(r.number.push(i),s.push(D0),n.push(parseFloat(u))),++i,Zf)).split(Zf);return{values:n,split:a,indexes:r,types:s}}function zk(e){return Vr(e).values}function I0({split:e,types:t}){const n=e.length;return r=>{let s="";for(let i=0;itypeof e=="number"?0:je.test(e)?je.getAnimatableNone(e):e,$k=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:Hk(e);function Uk(e){const t=Vr(e);return I0(t)(t.values.map((r,s)=>$k(r,t.split[s])))}const Nt={test:Ik,parse:zk,createTransformer:Bk,getAnimatableNone:Uk};function Ua(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Wk({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let s=0,i=0,o=0;if(!t)s=i=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,u=2*n-a;s=Ua(u,a,e+1/3),i=Ua(u,a,e),o=Ua(u,a,e-1/3)}return{red:Math.round(s*255),green:Math.round(i*255),blue:Math.round(o*255),alpha:r}}function No(e,t){return n=>n>0?t:e}const le=(e,t,n)=>e+(t-e)*n,Wa=(e,t,n)=>{const r=e*e,s=n*(t*t-r)+r;return s<0?0:Math.sqrt(s)},Gk=[du,zn,xr],Kk=e=>Gk.find(t=>t.test(e));function Qf(e){const t=Kk(e);if(!t)return!1;let n=t.parse(e);return t===xr&&(n=Wk(n)),n}const Jf=(e,t)=>{const n=Qf(e),r=Qf(t);if(!n||!r)return No(e,t);const s={...n};return i=>(s.red=Wa(n.red,r.red,i),s.green=Wa(n.green,r.green,i),s.blue=Wa(n.blue,r.blue,i),s.alpha=le(n.alpha,r.alpha,i),zn.transform(s))},fu=new Set(["none","hidden"]);function qk(e,t){return fu.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Yk(e,t){return n=>le(e,t,n)}function Jc(e){return typeof e=="number"?Yk:typeof e=="string"?Xc(e)?No:je.test(e)?Jf:Qk:Array.isArray(e)?V0:typeof e=="object"?je.test(e)?Jf:Xk:No}function V0(e,t){const n=[...e],r=n.length,s=e.map((i,o)=>Jc(i)(i,t[o]));return i=>{for(let o=0;o{for(const i in r)n[i]=r[i](s);return n}}function Zk(e,t){const n=[],r={color:0,var:0,number:0};for(let s=0;s{const n=Nt.createTransformer(t),r=Vr(e),s=Vr(t);return r.indexes.var.length===s.indexes.var.length&&r.indexes.color.length===s.indexes.color.length&&r.indexes.number.length>=s.indexes.number.length?fu.has(e)&&!s.values.length||fu.has(t)&&!r.values.length?qk(e,t):ni(V0(Zk(r,s),s.values),n):No(e,t)};function F0(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?le(e,t,n):Jc(e)(e,t)}const Jk=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>Z.update(t,n),stop:()=>vt(t),now:()=>Me.isProcessing?Me.timestamp:We.now()}},O0=(e,t,n=10)=>{let r="";const s=Math.max(Math.round(t/n),2);for(let i=0;i=_o?1/0:t}function eb(e,t=100,n){const r=n({...e,keyframes:[0,t]}),s=Math.min(ed(r),_o);return{type:"keyframes",ease:i=>r.next(s*i).value/t,duration:pt(s)}}const ke={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function hu(e,t){return e*Math.sqrt(1-t*t)}const tb=12;function nb(e,t,n){let r=n;for(let s=1;s{const d=c*o,f=d*e,h=d-n,y=hu(c,o),x=Math.exp(-f);return Ga-h/y*x},i=c=>{const f=c*o*e,h=f*n+n,y=Math.pow(o,2)*Math.pow(c,2)*e,x=Math.exp(-f),w=hu(Math.pow(c,2),o);return(-s(c)+Ga>0?-1:1)*((h-y)*x)/w}):(s=c=>{const d=Math.exp(-c*e),f=(c-n)*e+1;return-Ga+d*f},i=c=>{const d=Math.exp(-c*e),f=(n-c)*(e*e);return d*f});const a=5/e,u=nb(s,i,a);if(e=at(e),isNaN(u))return{stiffness:ke.stiffness,damping:ke.damping,duration:e};{const c=Math.pow(u,2)*r;return{stiffness:c,damping:o*2*Math.sqrt(r*c),duration:e}}}const sb=["duration","bounce"],ib=["stiffness","damping","mass"];function eh(e,t){return t.some(n=>e[n]!==void 0)}function ob(e){let t={velocity:ke.velocity,stiffness:ke.stiffness,damping:ke.damping,mass:ke.mass,isResolvedFromDuration:!1,...e};if(!eh(e,ib)&&eh(e,sb))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),s=r*r,i=2*Mt(.05,1,1-(e.bounce||0))*Math.sqrt(s);t={...t,mass:ke.mass,stiffness:s,damping:i}}else{const n=rb({...e,velocity:0});t={...t,...n,mass:ke.mass},t.isResolvedFromDuration=!0}return t}function Mo(e=ke.visualDuration,t=ke.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:s}=n;const i=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:u,damping:c,mass:d,duration:f,velocity:h,isResolvedFromDuration:y}=ob({...n,velocity:-pt(n.velocity||0)}),x=h||0,w=c/(2*Math.sqrt(u*d)),b=o-i,m=pt(Math.sqrt(u/d)),g=Math.abs(b)<5;r||(r=g?ke.restSpeed.granular:ke.restSpeed.default),s||(s=g?ke.restDelta.granular:ke.restDelta.default);let v,k,S,C,j,P;if(w<1)S=hu(m,w),C=(x+w*m*b)/S,v=E=>{const O=Math.exp(-w*m*E);return o-O*(C*Math.sin(S*E)+b*Math.cos(S*E))},j=w*m*C+b*S,P=w*m*b-C*S,k=E=>Math.exp(-w*m*E)*(j*Math.sin(S*E)+P*Math.cos(S*E));else if(w===1){v=O=>o-Math.exp(-m*O)*(b+(x+m*b)*O);const E=x+m*b;k=O=>Math.exp(-m*O)*(m*E*O-x)}else{const E=m*Math.sqrt(w*w-1);v=$=>{const se=Math.exp(-w*m*$),G=Math.min(E*$,300);return o-se*((x+w*m*b)*Math.sinh(G)+E*b*Math.cosh(G))/E};const O=(x+w*m*b)/E,K=w*m*O-b*E,H=w*m*b-O*E;k=$=>{const se=Math.exp(-w*m*$),G=Math.min(E*$,300);return se*(K*Math.sinh(G)+H*Math.cosh(G))}}const M={calculatedDuration:y&&f||null,velocity:E=>at(k(E)),next:E=>{if(!y&&w<1){const K=Math.exp(-w*m*E),H=Math.sin(S*E),$=Math.cos(S*E),se=o-K*(C*H+b*$),G=at(K*(j*H+P*$));return a.done=Math.abs(G)<=r&&Math.abs(o-se)<=s,a.value=a.done?o:se,a}const O=v(E);if(y)a.done=E>=f;else{const K=at(k(E));a.done=Math.abs(K)<=r&&Math.abs(o-O)<=s}return a.value=a.done?o:O,a},toString:()=>{const E=Math.min(ed(M),_o),O=O0(K=>M.next(E*K).value,E,30);return E+"ms "+O},toTransition:()=>{}};return M}Mo.applyToOptions=e=>{const t=eb(e,100,Mo);return e.ease=t.ease,e.duration=at(t.duration),e.type="keyframes",e};const ab=5;function z0(e,t,n){const r=Math.max(t-ab,0);return Kc(n-e(r),t-r)}function mu({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:s=10,bounceStiffness:i=500,modifyTarget:o,min:a,max:u,restDelta:c=.5,restSpeed:d}){const f=e[0],h={done:!1,value:f},y=P=>a!==void 0&&Pu,x=P=>a===void 0?u:u===void 0||Math.abs(a-P)-w*Math.exp(-P/r),v=P=>m+g(P),k=P=>{const M=g(P),E=v(P);h.done=Math.abs(M)<=c,h.value=h.done?m:E};let S,C;const j=P=>{y(h.value)&&(S=P,C=Mo({keyframes:[h.value,x(h.value)],velocity:z0(v,P,h.value),damping:s,stiffness:i,restDelta:c,restSpeed:d}))};return j(0),{calculatedDuration:null,next:P=>{let M=!1;return!C&&S===void 0&&(M=!0,k(P),j(P)),S!==void 0&&P>=S?C.next(P-S):(!M&&k(P),h)}}}function lb(e,t,n){const r=[],s=n||Tn.mix||F0,i=e.length-1;for(let o=0;ot[0];if(i===2&&t[0]===t[1])return()=>t[1];const o=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=lb(t,r,s),u=a.length,c=d=>{if(o&&d1)for(;fc(Mt(e[0],e[i-1],d)):c}function ub(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const s=Ir(0,t,r);e.push(le(n,1,s))}}function B0(e){const t=[0];return ub(t,e.length-1),t}function cb(e,t){return e.map(n=>n*t)}function db(e,t){return e.map(()=>t||E0).splice(0,e.length-1)}function bs({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const s=kk(r)?r.map(qf):qf(r),i={done:!1,value:t[0]},o=cb(n&&n.length===t.length?n:B0(t),e),a=td(o,t,{ease:Array.isArray(s)?s:db(t,s)});return{calculatedDuration:e,next:u=>(i.value=a(u),i.done=u>=e,i)}}const fb=e=>e!==null;function aa(e,{repeat:t,repeatType:n="loop"},r,s=1){const i=e.filter(fb),a=s<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||r===void 0?i[a]:r}const hb={decay:mu,inertia:mu,tween:bs,keyframes:bs,spring:Mo};function H0(e){typeof e.type=="string"&&(e.type=hb[e.type])}class nd{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const mb=e=>e/100;class Ks extends nd{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,s;const{motionValue:n}=this.options;n&&n.updatedAt!==We.now()&&this.tick(We.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(s=(r=this.options).onStop)==null||s.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;H0(t);const{type:n=bs,repeat:r=0,repeatDelay:s=0,repeatType:i,velocity:o=0}=t;let{keyframes:a}=t;const u=n||bs;u!==bs&&typeof a[0]!="number"&&(this.mixKeyframes=ni(mb,F0(a[0],a[1])),a=[0,100]);const c=u({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=u({...t,keyframes:[...a].reverse(),velocity:-o})),c.calculatedDuration===null&&(c.calculatedDuration=ed(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+s,this.totalDuration=this.resolvedDuration*(r+1)-s,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:s,mixKeyframes:i,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:u}=this;if(this.startTime===null)return r.next(0);const{delay:c=0,keyframes:d,repeat:f,repeatType:h,repeatDelay:y,type:x,onUpdate:w,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-s/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const m=this.currentTime-c*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?m<0:m>s;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=s);let v=this.currentTime,k=r;if(f){const P=Math.min(this.currentTime,s)/a;let M=Math.floor(P),E=P%1;!E&&P>=1&&(E=1),E===1&&M--,M=Math.min(M,f+1),!!(M%2)&&(h==="reverse"?(E=1-E,y&&(E-=y/a)):h==="mirror"&&(k=o)),v=Mt(0,1,E)*a}let S;g?(this.delayState.value=d[0],S=this.delayState):S=k.next(v),i&&!g&&(S.value=i(S.value));let{done:C}=S;!g&&u!==null&&(C=this.playbackSpeed>=0?this.currentTime>=s:this.currentTime<=0);const j=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&C);return j&&x!==mu&&(S.value=aa(d,this.options,b,this.speed)),w&&w(S.value),j&&this.finish(),S}then(t,n){return this.finished.then(t,n)}get duration(){return pt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pt(t)}get time(){return pt(this.currentTime)}set time(t){t=at(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return z0(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(We.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=pt(this.currentTime))}play(){var s,i;if(this.isStopped)return;const{driver:t=Jk,startTime:n}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),(i=(s=this.options).onPlay)==null||i.call(s);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(We.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function pb(e){for(let t=1;te*180/Math.PI,pu=e=>{const t=Bn(Math.atan2(e[1],e[0]));return gu(t)},gb={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:pu,rotateZ:pu,skewX:e=>Bn(Math.atan(e[1])),skewY:e=>Bn(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},gu=e=>(e=e%360,e<0&&(e+=360),e),th=pu,nh=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),rh=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),yb={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:nh,scaleY:rh,scale:e=>(nh(e)+rh(e))/2,rotateX:e=>gu(Bn(Math.atan2(e[6],e[5]))),rotateY:e=>gu(Bn(Math.atan2(-e[2],e[0]))),rotateZ:th,rotate:th,skewX:e=>Bn(Math.atan(e[4])),skewY:e=>Bn(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function yu(e){return e.includes("scale")?1:0}function xu(e,t){if(!e||e==="none")return yu(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,s;if(n)r=yb,s=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=gb,s=a}if(!s)return yu(t);const i=r[t],o=s[1].split(",").map(vb);return typeof i=="function"?i(o):o[i]}const xb=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return xu(n,t)};function vb(e){return parseFloat(e.trim())}const Gr=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Kr=new Set([...Gr,"pathRotation"]),sh=e=>e===Wr||e===R,wb=new Set(["x","y","z"]),kb=Gr.filter(e=>!wb.has(e));function bb(e){const t=[];return kb.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const hn={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>xu(t,"x"),y:(e,{transform:t})=>xu(t,"y")};hn.translateX=hn.x;hn.translateY=hn.y;const Un=new Set;let vu=!1,wu=!1,ku=!1;function $0(){if(wu){const e=Array.from(Un).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const s=bb(r);s.length&&(n.set(r,s),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const s=n.get(r);s&&s.forEach(([i,o])=>{var a;(a=r.getValue(i))==null||a.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}wu=!1,vu=!1,Un.forEach(e=>e.complete(ku)),Un.clear()}function U0(){Un.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(wu=!0)})}function Sb(){ku=!0,U0(),$0(),ku=!1}class rd{constructor(t,n,r,s,i,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=s,this.element=i,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(Un.add(this),vu||(vu=!0,Z.read(U0),Z.resolveKeyframes($0))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:s}=this;if(t[0]===null){const i=s==null?void 0:s.get(),o=t[t.length-1];if(i!==void 0)t[0]=i;else if(r&&n){const a=r.readValue(n,o);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=o),s&&i===void 0&&s.set(t[0])}pb(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Un.delete(this)}cancel(){this.state==="scheduled"&&(Un.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Pb=e=>e.startsWith("--");function W0(e,t,n){Pb(t)?e.style.setProperty(t,n):e.style[t]=n}const jb={};function sd(e,t){const n=v0(e);return()=>jb[t]??n()}const id=sd(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),G0=sd(()=>window.ViewTimeline!==void 0,"viewTimeline"),K0=sd(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),cs=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,ih={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:cs([0,.65,.55,1]),circOut:cs([.55,0,1,.45]),backIn:cs([.31,.01,.66,-.59]),backOut:cs([.33,1.53,.69,.99])};function q0(e,t){if(e)return typeof e=="function"?K0()?O0(e,t):"ease-out":N0(e)?cs(e):Array.isArray(e)?e.map(n=>q0(n,t)||ih.easeOut):ih[e]}function Cb(e,t,n,{delay:r=0,duration:s=300,repeat:i=0,repeatType:o="loop",ease:a="easeOut",times:u}={},c=void 0){const d={[t]:n};u&&(d.offset=u);const f=q0(a,s);Array.isArray(f)&&(d.easing=f);const h={delay:r,duration:s,easing:Array.isArray(f)?"linear":f,fill:"both",iterations:i+1,direction:o==="reverse"?"alternate":"normal"};return c&&(h.pseudoElement=c),e.animate(d,h)}function Y0(e){return typeof e=="function"&&"applyToOptions"in e}function Tb({type:e,...t}){return Y0(e)&&K0()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class X0 extends nd{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:s,pseudoElement:i,allowFlatten:o=!1,finalKeyframe:a,onComplete:u}=t;this.isPseudoElement=!!i,this.allowFlatten=o,this.options=t,Wc(typeof t.type!="string");const c=Tb(t);this.animation=Cb(n,r,s,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const d=aa(s,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(d),W0(n,r,d),this.animation.cancel()}u==null||u(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,s;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((s=(r=this.animation).commitStyles)==null||s.call(r))}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return pt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pt(t)}get time(){return pt(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=at(t),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:s}){var i;return this.allowFlatten&&((i=this.animation.effect)==null||i.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&id()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),tt):s(this)}}const Z0={anticipate:j0,backInOut:P0,circInOut:T0};function Eb(e){return e in Z0}function Nb(e){typeof e.ease=="string"&&Eb(e.ease)&&(e.ease=Z0[e.ease])}const Ka=10;class _b extends X0{constructor(t){Nb(t),H0(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:s,element:i,...o}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new Ks({...o,autoplay:!1}),u=Math.max(Ka,We.now()-this.startTime),c=Mt(0,Ka,u-Ka),d=a.sample(u).value,{name:f}=this.options;i&&f&&W0(i,f,d),n.setWithVelocity(a.sample(Math.max(0,u-c)).value,d,c),a.stop()}}const oh=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Nt.test(e)||e==="0")&&!e.startsWith("url("));function Mb(e){const t=e[0];if(e.length===1)return!0;for(let n=0;nObject.hasOwnProperty.call(Element.prototype,"animate"));function Vb(e){var f;const{motionValue:t,name:n,repeatDelay:r,repeatType:s,damping:i,type:o,keyframes:a}=e;if(!(((f=t==null?void 0:t.owner)==null?void 0:f.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:d}=t.owner.getProps();return Ib()&&n&&(Q0.has(n)||Rb.has(n)&&Db(a))&&(n!=="transform"||!d)&&!c&&!r&&s!=="mirror"&&i!==0&&o!=="inertia"}const Fb=40;class Ob extends nd{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:o="loop",keyframes:a,name:u,motionValue:c,element:d,...f}){var x;super(),this.stop=()=>{var w,b;this._animation&&(this._animation.stop(),(w=this.stopTimeline)==null||w.call(this)),(b=this.keyframeResolver)==null||b.cancel()},this.createdAt=We.now();const h={autoplay:t,delay:n,type:r,repeat:s,repeatDelay:i,repeatType:o,name:u,motionValue:c,element:d,...f},y=(d==null?void 0:d.KeyframeResolver)||rd;this.keyframeResolver=new y(a,(w,b,m)=>this.onKeyframesResolved(w,b,h,!m),u,c,d),(x=this.keyframeResolver)==null||x.scheduleResolve()}onKeyframesResolved(t,n,r,s){var m,g;this.keyframeResolver=void 0;const{name:i,type:o,velocity:a,delay:u,isHandoff:c,onUpdate:d}=r;this.resolvedAt=We.now();let f=!0;Lb(t,i,o,a)||(f=!1,(Tn.instantAnimations||!u)&&(d==null||d(aa(t,r,n))),t[0]=t[t.length-1],bu(r),r.repeat=0);const y={startTime:s?this.resolvedAt?this.resolvedAt-this.createdAt>Fb?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},x=f&&!c&&Vb(y),w=(g=(m=y.motionValue)==null?void 0:m.owner)==null?void 0:g.current;let b;if(x)try{b=new _b({...y,element:w})}catch{b=new Ks(y)}else b=new Ks(y);b.finished.then(()=>{this.notifyFinished()}).catch(tt),this.pendingTimeline&&(this.stopTimeline=b.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=b}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),Sb()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}function J0(e,t,n,r=0,s=1){const i=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),o=e.size,a=(o-1)*r;return typeof n=="function"?n(i,o):s===1?i*r:a-i*r}const ah=30,zb=e=>!isNaN(parseFloat(e)),Ss={current:void 0};class Bb{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var i;const s=We.now();if(this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((i=this.events.change)==null||i.notify(this.current),this.dependents))for(const o of this.dependents)o.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=We.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=zb(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Gc);const r=this.events[t].add(n);return t==="change"?()=>{r(),Z.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return Ss.current&&Ss.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=We.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>ah)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,ah);return Kc(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Ct(e,t){return new Bb(e,t)}function od(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function ad(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?od(n,e):n}const Hb={type:"spring",stiffness:500,damping:25,restSpeed:10},$b=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Ub={type:"keyframes",duration:.8},Wb={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Gb=(e,{keyframes:t})=>t.length>2?Ub:Kr.has(e)?e.startsWith("scale")?$b(t[1]):Hb:Wb,Kb=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function qb(e){for(const t in e)if(!Kb.has(t))return!0;return!1}const ld=(e,t,n,r={},s,i)=>o=>{const a=ad(r,e)||{},u=a.delay||r.delay||0;let{elapsed:c=0}=r;c=c-at(u);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:s};qb(a)||Object.assign(d,Gb(e,d)),d.duration&&(d.duration=at(d.duration)),d.repeatDelay&&(d.repeatDelay=at(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let f=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(bu(d),d.delay===0&&(f=!0)),(Tn.instantAnimations||Tn.skipAnimations||s!=null&&s.shouldSkipAnimations||a.skipAnimations)&&(f=!0,bu(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,f&&!i&&t.get()!==void 0){const h=aa(d.keyframes,a);if(h!==void 0){Z.update(()=>{d.onUpdate(h),d.onComplete()});return}}return a.isSync?new Ks(d):new Ob(d)},Yb=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Xb(e){const t=Yb.exec(e);if(!t)return[,];const[,n,r,s]=t;return[`--${n??r}`,s]}function ey(e,t,n=1){const[r,s]=Xb(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const o=i.trim();return g0(o)?parseFloat(o):o}return Xc(s)?ey(s,t,n+1):s}function lh(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function ud(e,t,n,r){if(typeof t=="function"){const[s,i]=lh(r);t=t(n!==void 0?n:e.custom,s,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[s,i]=lh(r);t=t(n!==void 0?n:e.custom,s,i)}return t}function Wn(e,t,n){const r=e.getProps();return ud(r,t,n!==void 0?n:r.custom,e)}const ty=new Set(["width","height","top","left","right","bottom",...Gr]),Su=e=>Array.isArray(e);function Zb(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Ct(n))}function Qb(e){return Su(e)?e[e.length-1]||0:e}function Jb(e,t){const n=Wn(e,t);let{transitionEnd:r={},transition:s={},...i}=n||{};i={...i,...r};for(const o in i){const a=Qb(i[o]);Zb(e,o,a)}}const _e=e=>!!(e&&e.getVelocity);function eS(e){return!!(_e(e)&&e.add)}function Pu(e,t){const n=e.getValue("willChange");if(eS(n))return n.add(t);if(!n&&Tn.WillChange){const r=new Tn.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function cd(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const tS="framerAppearId",ny="data-"+cd(tS);function ry(e){return e.props[ny]}function nS({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function sy(e,t,{delay:n=0,transitionOverride:r,type:s}={}){let{transition:i,transitionEnd:o,...a}=t;const u=e.getDefaultTransition();i=i?od(i,u):u;const c=i==null?void 0:i.reduceMotion,d=i==null?void 0:i.skipAnimations;r&&(i=r);const f=[],h=s&&e.animationState&&e.animationState.getState()[s],y=i==null?void 0:i.path;y&&y.animateVisualElement(e,a,i,n,f);for(const x in a){const w=e.getValue(x,e.latestValues[x]??null),b=a[x];if(b===void 0||h&&nS(h,x))continue;const m={delay:n,...ad(i||{},x)};d&&(m.skipAnimations=!0);const g=w.get();if(g!==void 0&&!w.isAnimating()&&!Array.isArray(b)&&b===g&&!m.velocity){Z.update(()=>w.set(b));continue}let v=!1;if(window.MotionHandoffAnimation){const C=ry(e);if(C){const j=window.MotionHandoffAnimation(C,x,Z);j!==null&&(m.startTime=j,v=!0)}}Pu(e,x);const k=c??e.shouldReduceMotion;w.start(ld(x,w,b,k&&ty.has(x)?{type:!1}:m,e,v));const S=w.animation;S&&f.push(S)}if(o){const x=()=>Z.update(()=>{o&&Jb(e,o)});f.length?Promise.all(f).then(x):x()}return f}function ju(e,t,n={}){var u;const r=Wn(e,t,n.type==="exit"?(u=e.presenceContext)==null?void 0:u.custom:void 0);let{transition:s=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(s=n.transitionOverride);const i=r?()=>Promise.all(sy(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:d=0,staggerChildren:f,staggerDirection:h}=s;return rS(e,t,c,d,f,h,n)}:()=>Promise.resolve(),{when:a}=s;if(a){const[c,d]=a==="beforeChildren"?[i,o]:[o,i];return c().then(()=>d())}else return Promise.all([i(),o(n.delay)])}function rS(e,t,n=0,r=0,s=0,i=1,o){const a=[];for(const u of e.variantChildren)u.notify("AnimationStart",t),a.push(ju(u,t,{...o,delay:n+(typeof r=="function"?0:r)+J0(e.variantChildren,u,r,s,i)}).then(()=>u.notify("AnimationComplete",t)));return Promise.all(a)}function sS(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const s=t.map(i=>ju(e,i,n));r=Promise.all(s)}else if(typeof t=="string")r=ju(e,t,n);else{const s=typeof t=="function"?Wn(e,t,n.custom):t;r=Promise.all(sy(e,s,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const iS={test:e=>e==="auto",parse:e=>e},iy=e=>t=>t.test(e),oy=[Wr,R,zt,Ht,Dk,Ak,iS],uh=e=>oy.find(iy(e));function oS(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||x0(e):!0}const aS=new Set(["brightness","contrast","saturate","opacity"]);function lS(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Zc)||[];if(!r)return e;const s=n.replace(r,"");let i=aS.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+s+")"}const uS=/\b([a-z-]*)\(.*?\)/gu,Cu={...Nt,getAnimatableNone:e=>{const t=e.match(uS);return t?t.map(lS).join(" "):e}},Tu={...Nt,getAnimatableNone:e=>{const t=Nt.parse(e);return Nt.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},ch={...Wr,transform:Math.round},cS={rotate:Ht,pathRotation:Ht,rotateX:Ht,rotateY:Ht,rotateZ:Ht,scale:Ci,scaleX:Ci,scaleY:Ci,scaleZ:Ci,skew:Ht,skewX:Ht,skewY:Ht,distance:R,translateX:R,translateY:R,translateZ:R,x:R,y:R,z:R,perspective:R,transformPerspective:R,opacity:Gs,originX:Xf,originY:Xf,originZ:R},Lo={borderWidth:R,borderTopWidth:R,borderRightWidth:R,borderBottomWidth:R,borderLeftWidth:R,borderRadius:R,borderTopLeftRadius:R,borderTopRightRadius:R,borderBottomRightRadius:R,borderBottomLeftRadius:R,width:R,maxWidth:R,height:R,maxHeight:R,top:R,right:R,bottom:R,left:R,inset:R,insetBlock:R,insetBlockStart:R,insetBlockEnd:R,insetInline:R,insetInlineStart:R,insetInlineEnd:R,padding:R,paddingTop:R,paddingRight:R,paddingBottom:R,paddingLeft:R,paddingBlock:R,paddingBlockStart:R,paddingBlockEnd:R,paddingInline:R,paddingInlineStart:R,paddingInlineEnd:R,margin:R,marginTop:R,marginRight:R,marginBottom:R,marginLeft:R,marginBlock:R,marginBlockStart:R,marginBlockEnd:R,marginInline:R,marginInlineStart:R,marginInlineEnd:R,fontSize:R,backgroundPositionX:R,backgroundPositionY:R,...cS,zIndex:ch,fillOpacity:Gs,strokeOpacity:Gs,numOctaves:ch},dS={...Lo,color:je,backgroundColor:je,outlineColor:je,fill:je,stroke:je,borderColor:je,borderTopColor:je,borderRightColor:je,borderBottomColor:je,borderLeftColor:je,filter:Cu,WebkitFilter:Cu,mask:Tu,WebkitMask:Tu},ay=e=>dS[e],fS=new Set([Cu,Tu]);function ly(e,t){let n=ay(e);return fS.has(n)||(n=Nt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const hS=new Set(["auto","none","0"]);function mS(e,t,n){let r=0,s;for(;r{t.getValue(u).set(c)}),this.resolveNoneKeyframes()}}const dd=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function uy(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){const s=document.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e).filter(r=>r!=null)}const Eu=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Ps(e){return y0(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:Fr,cancel:cy}=_0(queueMicrotask,!1),bt={x:!1,y:!1};function dy(){return bt.x||bt.y}function gS(e){return e==="x"||e==="y"?bt[e]?null:(bt[e]=!0,()=>{bt[e]=!1}):bt.x||bt.y?null:(bt.x=bt.y=!0,()=>{bt.x=bt.y=!1})}function fy(e,t){const n=uy(e),r=new AbortController,s={passive:!0,...t,signal:r.signal};return[n,s,()=>r.abort()]}function yS(e){return!(e.pointerType==="touch"||dy())}function xS(e,t,n={}){const[r,s,i]=fy(e,n);return r.forEach(o=>{let a=!1,u=!1,c;const d=()=>{o.removeEventListener("pointerleave",x)},f=b=>{c&&(c(b),c=void 0),d()},h=b=>{a=!1,window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",h),u&&(u=!1,f(b))},y=()=>{a=!0,window.addEventListener("pointerup",h,s),window.addEventListener("pointercancel",h,s)},x=b=>{if(b.pointerType!=="touch"){if(a){u=!0;return}f(b)}},w=b=>{if(!yS(b))return;u=!1;const m=t(o,b);typeof m=="function"&&(c=m,o.addEventListener("pointerleave",x,s))};o.addEventListener("pointerenter",w,s),o.addEventListener("pointerdown",y,s)}),i}const hy=(e,t)=>t?e===t?!0:hy(e,t.parentElement):!1,fd=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,vS=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function wS(e){return vS.has(e.tagName)||e.isContentEditable===!0}const kS=new Set(["INPUT","SELECT","TEXTAREA"]);function bS(e){return kS.has(e.tagName)||e.isContentEditable===!0}const Gi=new WeakSet;function dh(e){return t=>{t.key==="Enter"&&e(t)}}function qa(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const SS=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=dh(()=>{if(Gi.has(n))return;qa(n,"down");const s=dh(()=>{qa(n,"up")}),i=()=>qa(n,"cancel");n.addEventListener("keyup",s,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function fh(e){return fd(e)&&!dy()}const hh=new WeakSet;function PS(e,t,n={}){const[r,s,i]=fy(e,n),o=a=>{const u=a.currentTarget;if(!fh(a)||hh.has(a))return;Gi.add(u),n.stopPropagation&&hh.add(a);const c=t(u,a),d={...s,capture:!0},f=(x,w)=>{window.removeEventListener("pointerup",h,d),window.removeEventListener("pointercancel",y,d),Gi.has(u)&&Gi.delete(u),fh(x)&&typeof c=="function"&&c(x,{success:w})},h=x=>{f(x,u===window||u===document||n.useGlobalTarget||hy(u,x.target))},y=x=>{f(x,!1)};window.addEventListener("pointerup",h,d),window.addEventListener("pointercancel",y,d)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,s),Ps(a)&&(a.addEventListener("focus",c=>SS(c,s)),!wS(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function hd(e){return y0(e)&&"ownerSVGElement"in e}const Ki=new WeakMap;let rn;const my=(e,t,n)=>(r,s)=>s&&s[0]?s[0][e+"Size"]:hd(r)&&"getBBox"in r?r.getBBox()[t]:r[n],jS=my("inline","width","offsetWidth"),CS=my("block","height","offsetHeight");function TS({target:e,borderBoxSize:t}){var n;(n=Ki.get(e))==null||n.forEach(r=>{r(e,{get width(){return jS(e,t)},get height(){return CS(e,t)}})})}function ES(e){e.forEach(TS)}function NS(){typeof ResizeObserver>"u"||(rn=new ResizeObserver(ES))}function _S(e,t){rn||NS();const n=uy(e);return n.forEach(r=>{let s=Ki.get(r);s||(s=new Set,Ki.set(r,s)),s.add(t),rn==null||rn.observe(r)}),()=>{n.forEach(r=>{const s=Ki.get(r);s==null||s.delete(t),s!=null&&s.size||rn==null||rn.unobserve(r)})}}const qi=new Set;let vr;function MS(){vr=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};qi.forEach(t=>t(e))},window.addEventListener("resize",vr)}function LS(e){return qi.add(e),vr||MS(),()=>{qi.delete(e),!qi.size&&typeof vr=="function"&&(window.removeEventListener("resize",vr),vr=void 0)}}function Nu(e,t){return typeof e=="function"?LS(e):_S(e,t)}function py(e,t){let n;const r=()=>{const{currentTime:s}=t,o=(s===null?0:s.value)/100;n!==o&&e(o),n=o};return Z.preUpdate(r,!0),()=>vt(r)}function AS(e){return hd(e)&&e.tagName==="svg"}function DS(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],s=e[1+n],i=e[2+n],o=e[3+n],a=td(s,i,o);return t?a(r):a}function RS(e,t,n={}){const r=e.get();let s=null,i=r,o;const a=typeof r=="string"?r.replace(/[\d.-]/g,""):void 0,u=()=>{s&&(s.stop(),s=null),e.animation=void 0},c=()=>{const f=mh(e.get()),h=mh(i);if(f===h){u();return}const y=s?s.getGeneratorVelocity():e.getVelocity();u(),s=new Ks({keyframes:[f,h],velocity:y,type:"spring",restDelta:.001,restSpeed:.01,...n,onUpdate:o})},d=()=>{var f;c(),e.animation=s??void 0,(f=e.events.animationStart)==null||f.notify(),s==null||s.then(()=>{var h;e.animation=void 0,(h=e.events.animationComplete)==null||h.notify()})};if(e.attach((f,h)=>{i=f,o=y=>h(Ya(y,a)),Z.postRender(d)},u),_e(t)){let f=n.skipInitialAnimation===!0;const h=t.on("change",x=>{f?(f=!1,e.jump(Ya(x,a),!1)):e.set(Ya(x,a))}),y=e.on("destroy",h);return()=>{h(),y()}}return u}function Ya(e,t){return t?e+t:e}function mh(e){return typeof e=="number"?e:parseFloat(e)}const IS=[...oy,je,Nt],VS=e=>IS.find(iy(e)),ph=()=>({translate:0,scale:1,origin:0,originPoint:0}),wr=()=>({x:ph(),y:ph()}),gh=()=>({min:0,max:0}),Te=()=>({x:gh(),y:gh()}),FS=new WeakMap;function la(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function qs(e){return typeof e=="string"||Array.isArray(e)}const md=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],pd=["initial",...md];function ua(e){return la(e.animate)||pd.some(t=>qs(e[t]))}function gy(e){return!!(ua(e)||e.variants)}function OS(e,t,n){for(const r in t){const s=t[r],i=n[r];if(_e(s))e.addValue(r,s);else if(_e(i))e.addValue(r,Ct(s,{owner:e}));else if(i!==s)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(s):o.hasAnimated||o.set(s)}else{const o=e.getStaticValue(r);e.addValue(r,Ct(o!==void 0?o:s,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const Ao={current:null},gd={current:!1},zS=typeof window<"u";function yy(){if(gd.current=!0,!!zS)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ao.current=e.matches;e.addEventListener("change",t),t()}else Ao.current=!1}const yh=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let Do={};function xy(e){Do=e}function BS(){return Do}class HS{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:s,skipAnimations:i,blockInitialAnimation:o,visualState:a},u={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=rd,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const y=We.now();this.renderScheduledAtthis.bindToMotionValue(i,s)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(gd.current||yy(),this.shouldReduceMotion=Ao.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),vt(this.notifyUpdate),vt(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&Q0.has(t)&&this.current instanceof HTMLElement){const{factory:o,keyframes:a,times:u,ease:c,duration:d}=n.accelerate,f=new X0({element:this.current,name:t,keyframes:a,times:u,ease:c,duration:at(d)}),h=o(f);this.valueSubscriptions.set(t,()=>{h(),f.cancel()});return}const r=Kr.has(t);r&&this.onBindTransform&&this.onBindTransform();const s=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&Z.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{s(),i&&i()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Do){const n=Do[t];if(!n)continue;const{isEnabled:r,Feature:s}=n;if(!this.features[t]&&s&&r(this.props)&&(this.features[t]=new s(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Te()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;rn.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Ct(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(g0(r)||x0(r))?r=parseFloat(r):!VS(r)&&Nt.test(n)&&(r=ly(t,n)),this.setBaseTarget(t,_e(r)?r.get():r)),_e(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var i;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const o=ud(this.props,n,(i=this.presenceContext)==null?void 0:i.custom);o&&(r=o[t])}if(n&&r!==void 0)return r;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!_e(s)?s:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Gc),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Fr.render(this.render)}}class vy extends HS{constructor(){super(...arguments),this.KeyframeResolver=pS}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;_e(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Mn{constructor(t){this.isMounted=!1,this.node=t}update(){}}function wy({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function $S({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function US(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Xa(e){return e===void 0||e===1}function _u({scale:e,scaleX:t,scaleY:n}){return!Xa(e)||!Xa(t)||!Xa(n)}function In(e){return _u(e)||ky(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function ky(e){return xh(e.x)||xh(e.y)}function xh(e){return e&&e!=="0%"}function Ro(e,t,n){const r=e-n,s=t*r;return n+s}function vh(e,t,n,r,s){return s!==void 0&&(e=Ro(e,s,r)),Ro(e,n,r)+t}function Mu(e,t=0,n=1,r,s){e.min=vh(e.min,t,n,r,s),e.max=vh(e.max,t,n,r,s)}function by(e,{x:t,y:n}){Mu(e.x,t.translate,t.scale,t.originPoint),Mu(e.y,n.translate,n.scale,n.originPoint)}const wh=.999999999999,kh=1.0000000000001;function WS(e,t,n,r=!1){var a;const s=n.length;if(!s)return;t.x=t.y=1;let i,o;for(let u=0;uwh&&(t.x=1),t.ywh&&(t.y=1)}function It(e,t){e.min+=t,e.max+=t}function bh(e,t,n,r,s=.5){const i=le(e.min,e.max,s);Mu(e,t,n,i,r)}function Sh(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function Yi(e,t,n){const r=n??e;bh(e.x,Sh(t.x,r.x),t.scaleX,t.scale,t.originX),bh(e.y,Sh(t.y,r.y),t.scaleY,t.scale,t.originY)}function Sy(e,t){return wy(US(e.getBoundingClientRect(),t))}function GS(e,t,n){const r=Sy(e,n),{scroll:s}=t;return s&&(It(r.x,s.offset.x),It(r.y,s.offset.y)),r}const KS={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},qS=Gr.length;function YS(e,t,n){let r="",s=!0;for(let o=0;o{if(!t.target)return e;if(typeof e=="string")if(R.test(e))e=parseFloat(e);else return e;const n=Ph(e,t.target.x),r=Ph(e,t.target.y);return`${n}% ${r}%`}},XS={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,s=Nt.parse(e);if(s.length>5)return r;const i=Nt.createTransformer(e),o=typeof s[0]!="number"?1:0,a=n.x.scale*t.x,u=n.y.scale*t.y;s[0+o]/=a,s[1+o]/=u;const c=le(a,u,.5);return typeof s[2+o]=="number"&&(s[2+o]/=c),typeof s[3+o]=="number"&&(s[3+o]/=c),i(s)}},Lu={borderRadius:{...ss,applyTo:[...dd]},borderTopLeftRadius:ss,borderTopRightRadius:ss,borderBottomLeftRadius:ss,borderBottomRightRadius:ss,boxShadow:XS};function jy(e,{layout:t,layoutId:n}){return Kr.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Lu[e]||e==="opacity")}function xd(e,t,n){var o;const r=e.style,s=t==null?void 0:t.style,i={};if(!r)return i;for(const a in r)(_e(r[a])||s&&_e(s[a])||jy(a,e)||((o=n==null?void 0:n.getValue(a))==null?void 0:o.liveStyle)!==void 0)&&(i[a]=r[a]);return i}function ZS(e){return window.getComputedStyle(e)}class QS extends vy{constructor(){super(...arguments),this.type="html",this.renderInstance=Py}readValueFromInstance(t,n){var r;if(Kr.has(n))return(r=this.projection)!=null&&r.isProjecting?yu(n):xb(t,n);{const s=ZS(t),i=(L0(n)?s.getPropertyValue(n):s[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Sy(t,n)}build(t,n,r){yd(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return xd(t,n,r)}}const JS={offset:"stroke-dashoffset",array:"stroke-dasharray"},e2={offset:"strokeDashoffset",array:"strokeDasharray"};function t2(e,t,n=1,r=0,s=!0){e.pathLength=1;const i=s?JS:e2;e[i.offset]=`${-r}`,e[i.array]=`${t} ${n}`}const n2=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function Cy(e,{attrX:t,attrY:n,attrScale:r,pathLength:s,pathSpacing:i=1,pathOffset:o=0,...a},u,c,d){if(yd(e,a,c),u){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:f,style:h}=e;f.transform&&(h.transform=f.transform,delete f.transform),(h.transform||f.transformOrigin)&&(h.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),h.transform&&(h.transformBox=(d==null?void 0:d.transformBox)??"fill-box",delete f.transformBox);for(const y of n2)f[y]!==void 0&&(h[y]=f[y],delete f[y]);t!==void 0&&(f.x=t),n!==void 0&&(f.y=n),r!==void 0&&(f.scale=r),s!==void 0&&t2(f,s,i,o,!1)}const Ty=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),Ey=e=>typeof e=="string"&&e.toLowerCase()==="svg";function r2(e,t,n,r){Py(e,t,void 0,r);for(const s in t.attrs)e.setAttribute(Ty.has(s)?s:cd(s),t.attrs[s])}function Ny(e,t,n){const r=xd(e,t,n);for(const s in e)if(_e(e[s])||_e(t[s])){const i=Gr.indexOf(s)!==-1?"attr"+s.charAt(0).toUpperCase()+s.substring(1):s;r[i]=e[s]}return r}class s2 extends vy{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Te}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Kr.has(n)){const r=ay(n);return r&&r.default||0}return n=Ty.has(n)?n:cd(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return Ny(t,n,r)}build(t,n,r){Cy(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,s){r2(t,n,r,s)}mount(t){this.isSVGTag=Ey(t.tagName),super.mount(t)}}const i2=pd.length;function _y(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?_y(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;nPromise.all(t.map(({animation:n,options:r})=>sS(e,n,r)))}function u2(e){let t=l2(e),n=jh(),r=!0,s=!1;const i=c=>(d,f)=>{var y;const h=Wn(e,f,c==="exit"?(y=e.presenceContext)==null?void 0:y.custom:void 0);if(h){const{transition:x,transitionEnd:w,...b}=h;d={...d,...b,...w}}return d};function o(c){t=c(e)}function a(c){const{props:d}=e,f=_y(e.parent)||{},h=[],y=new Set;let x={},w=1/0;for(let m=0;mw&&S,E=!1;const O=Array.isArray(k)?k:[k];let K=O.reduce(i(g),{});C===!1&&(K={});const{prevResolvedValues:H={}}=v,$={...H,...K},se=N=>{M=!0,y.has(N)&&(E=!0,y.delete(N)),v.needsAnimating[N]=!0;const L=e.getValue(N);L&&(L.liveStyle=!1)};for(const N in $){const L=K[N],F=H[N];if(x.hasOwnProperty(N))continue;let T=!1;Su(L)&&Su(F)?T=!My(L,F)||P:T=L!==F,T?L!=null?se(N):y.add(N):L!==void 0&&y.has(N)?se(N):v.protectedKeys[N]=!0}v.prevProp=k,v.prevResolvedValues=K,v.isActive&&(x={...x,...K}),(r||s)&&e.blockInitialAnimation&&(M=!1);const G=j&&P;M&&(!G||E)&&h.push(...O.map(N=>{const L={type:g};if(typeof N=="string"&&(r||s)&&!G&&e.manuallyAnimateOnMount&&e.parent){const{parent:F}=e,T=Wn(F,N);if(F.enteringChildren&&T){const{delayChildren:A}=T.transition||{};L.delay=J0(F.enteringChildren,e,A)}}return{animation:N,options:L}}))}if(y.size){const m={};if(typeof d.initial!="boolean"){const g=Wn(e,Array.isArray(d.initial)?d.initial[0]:d.initial);g&&g.transition&&(m.transition=g.transition)}y.forEach(g=>{const v=e.getBaseTarget(g),k=e.getValue(g);k&&(k.liveStyle=!0),m[g]=v??null}),h.push({animation:m})}let b=!!h.length;return r&&(d.initial===!1||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(b=!1),r=!1,s=!1,b?t(h):Promise.resolve()}function u(c,d){var h;if(n[c].isActive===d)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(y=>{var x;return(x=y.animationState)==null?void 0:x.setActive(c,d)}),n[c].isActive=d;const f=a(c);for(const y in n)n[y].protectedKeys={};return f}return{animateChanges:a,setActive:u,setAnimateFunction:o,getState:()=>n,reset:()=>{n=jh(),s=!0}}}function c2(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!My(t,e):!1}function An(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function jh(){return{animate:An(!0),whileInView:An(),whileHover:An(),whileTap:An(),whileDrag:An(),whileFocus:An(),exit:An()}}function Au(e,t){e.min=t.min,e.max=t.max}function kt(e,t){Au(e.x,t.x),Au(e.y,t.y)}function Ch(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const Ly=1e-4,d2=1-Ly,f2=1+Ly,Ay=.01,h2=0-Ay,m2=0+Ay;function Ge(e){return e.max-e.min}function p2(e,t,n){return Math.abs(e-t)<=n}function Th(e,t,n,r=.5){e.origin=r,e.originPoint=le(t.min,t.max,e.origin),e.scale=Ge(n)/Ge(t),e.translate=le(n.min,n.max,e.origin)-e.originPoint,(e.scale>=d2&&e.scale<=f2||isNaN(e.scale))&&(e.scale=1),(e.translate>=h2&&e.translate<=m2||isNaN(e.translate))&&(e.translate=0)}function js(e,t,n,r){Th(e.x,t.x,n.x,r?r.originX:void 0),Th(e.y,t.y,n.y,r?r.originY:void 0)}function Eh(e,t,n,r=0){const s=r?le(n.min,n.max,r):n.min;e.min=s+t.min,e.max=e.min+Ge(t)}function g2(e,t,n,r){Eh(e.x,t.x,n.x,r==null?void 0:r.x),Eh(e.y,t.y,n.y,r==null?void 0:r.y)}function Nh(e,t,n,r=0){const s=r?le(n.min,n.max,r):n.min;e.min=t.min-s,e.max=e.min+Ge(t)}function Io(e,t,n,r){Nh(e.x,t.x,n.x,r==null?void 0:r.x),Nh(e.y,t.y,n.y,r==null?void 0:r.y)}function _h(e,t,n,r,s){return e-=t,e=Ro(e,1/n,r),s!==void 0&&(e=Ro(e,1/s,r)),e}function y2(e,t=0,n=1,r=.5,s,i=e,o=e){if(zt.test(t)&&(t=parseFloat(t),t=le(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=le(i.min,i.max,r);e===i&&(a-=t),e.min=_h(e.min,t,n,a,s),e.max=_h(e.max,t,n,a,s)}function Mh(e,t,[n,r,s],i,o){y2(e,t[n],t[r],t[s],t.scale,i,o)}const x2=["x","scaleX","originX"],v2=["y","scaleY","originY"];function Lh(e,t,n,r){Mh(e.x,t,x2,n?n.x:void 0,r?r.x:void 0),Mh(e.y,t,v2,n?n.y:void 0,r?r.y:void 0)}function Ah(e){return e.translate===0&&e.scale===1}function Dy(e){return Ah(e.x)&&Ah(e.y)}function Dh(e,t){return e.min===t.min&&e.max===t.max}function w2(e,t){return Dh(e.x,t.x)&&Dh(e.y,t.y)}function Rh(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Ry(e,t){return Rh(e.x,t.x)&&Rh(e.y,t.y)}function Ih(e){return Ge(e.x)/Ge(e.y)}function Vh(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Rt(e){return[e("x"),e("y")]}function k2(e,t,n){let r="";const s=e.x.translate/t.x,i=e.y.translate/t.y,o=(n==null?void 0:n.z)||0;if((s||i||o)&&(r=`translate3d(${s}px, ${i}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,pathRotation:f,rotateX:h,rotateY:y,skewX:x,skewY:w}=n;c&&(r=`perspective(${c}px) ${r}`),d&&(r+=`rotate(${d}deg) `),f&&(r+=`rotate(${f}deg) `),h&&(r+=`rotateX(${h}deg) `),y&&(r+=`rotateY(${y}deg) `),x&&(r+=`skewX(${x}deg) `),w&&(r+=`skewY(${w}deg) `)}const a=e.x.scale*t.x,u=e.y.scale*t.y;return(a!==1||u!==1)&&(r+=`scale(${a}, ${u})`),r||"none"}const b2=dd.length,Fh=e=>typeof e=="string"?parseFloat(e):e,Oh=e=>typeof e=="number"||R.test(e);function S2(e,t,n,r,s,i){s?(e.opacity=le(0,n.opacity??1,P2(r)),e.opacityExit=le(t.opacity??1,0,j2(r))):i&&(e.opacity=le(t.opacity??1,n.opacity??1,r));for(let o=0;ort?1:n(Ir(e,t,r))}function C2(e,t,n){const r=_e(e)?e:Ct(e);return r.start(ld("",r,t,n)),r.animation}function Ys(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}const T2=(e,t)=>e.depth-t.depth;class E2{constructor(){this.children=[],this.isDirty=!1}add(t){Uc(this.children,t),this.isDirty=!0}remove(t){Eo(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(T2),this.isDirty=!1,this.children.forEach(t)}}function N2(e,t){const n=We.now(),r=({timestamp:s})=>{const i=s-n;i>=t&&(vt(r),e(i-t))};return Z.setup(r,!0),()=>vt(r)}function Xi(e){return _e(e)?e.get():e}class _2{constructor(){this.members=[]}add(t){Uc(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const s=r.instance;(!s||s.isConnected===!1)&&!r.snapshot&&(Eo(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(Eo(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const s=this.members[r];if(s.isPresent!==!1&&((n=s.instance)==null?void 0:n.isConnected)!==!1)return this.promote(s),!0}return!1}promote(t,n){var s;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:i}=r.options,{layoutDependency:o}=t.options;(i===void 0||i!==o)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(s=t.root)!=null&&s.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,s,i,o;(r=(n=t.options).onExitComplete)==null||r.call(n),(o=(s=t.resumingFrom)==null?void 0:(i=s.options).onExitComplete)==null||o.call(i)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const Zi={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Za=["","X","Y","Z"],M2=1e3;let L2=0;function Qa(e,t,n,r){const{latestValues:s}=t;s[e]&&(n[e]=s[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Vy(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=ry(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:s,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Z,!(s||i))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Vy(r)}function Fy({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:s}){return class{constructor(o={},a=t==null?void 0:t()){this.id=L2++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(R2),this.nodes.forEach(B2),this.nodes.forEach(H2),this.nodes.forEach(I2)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let u=0;uthis.root.updateBlockedByResize=!1;Z.read(()=>{f=window.innerWidth}),e(o,()=>{const y=window.innerWidth;y!==f&&(f=y,this.root.updateBlockedByResize=!0,d&&d(),d=N2(h,250),Zi.hasAnimatedSinceResize&&(Zi.hasAnimatedSinceResize=!1,this.nodes.forEach($h)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||u)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeLayoutChanged:h,layout:y})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const x=this.options.transition||c.getDefaultTransition()||K2,{onLayoutAnimationStart:w,onLayoutAnimationComplete:b}=c.getProps(),m=!this.targetLayout||!Ry(this.targetLayout,y),g=!f&&h;if(this.options.layoutRoot||this.resumeFrom||g||f&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const v={...ad(x,"layout"),onPlay:w,onComplete:b};(c.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v),this.setAnimationOrigin(d,g,v.path)}else f||$h(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=y})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),vt(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach($2),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Vy(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ge(this.snapshot.measuredBox.x)&&!Ge(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u{const j=C/1e3,P=S==null?void 0:S(j);P?(h.x.translate=P.x,h.x.scale=le(o.x.scale,1,j),h.x.origin=o.x.origin,h.x.originPoint=o.x.originPoint,h.y.translate=P.y,h.y.scale=le(o.y.scale,1,j),h.y.origin=o.y.origin,h.y.originPoint=o.y.originPoint):(Uh(h.x,o.x,j),Uh(h.y,o.y,j)),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Io(y,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),W2(this.relativeTarget,this.relativeTargetOrigin,y,j),k&&w2(this.relativeTarget,k)&&(this.isProjectionDirty=!1),k||(k=Te()),kt(k,this.relativeTarget)),b&&(this.animationValues=f,S2(f,d,this.latestValues,j,v,g)),P&&P.rotate!==void 0&&(this.animationValues||(this.animationValues=f),this.animationValues.pathRotation=P.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=j},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){var a,u,c;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(c=(u=this.resumingFrom)==null?void 0:u.currentAnimation)==null||c.stop(),this.pendingAnimation&&(vt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Z.update(()=>{Zi.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Ct(0)),this.motionValue.jump(0,!1),this.currentAnimation=C2(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:d=>{this.mixTargetDelta(d),o.onUpdate&&o.onUpdate(d)},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(M2),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:u,layout:c,latestValues:d}=o;if(!(!a||!u||!c)){if(this!==o&&this.layout&&c&&Oy(this.options.animationType,this.layout.layoutBox,c.layoutBox)){u=this.target||Te();const f=Ge(this.layout.layoutBox.x);u.x.min=o.target.x.min,u.x.max=u.x.min+f;const h=Ge(this.layout.layoutBox.y);u.y.min=o.target.y.min,u.y.max=u.y.min+h}kt(a,u),Yi(a,d),js(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new _2),this.sharedNodes.get(o).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var a;const{layoutId:o}=this.options;return o?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:o}=this.options;return o?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:u}={}){const c=this.getStack();c&&c.promote(this,u),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:u}=o;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(a=!0),!a)return;const c={};u.z&&Qa("z",o,c,this.animationValues);for(let d=0;d{var a;return(a=o.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Bh),this.root.sharedNodes.clear()}}}function A2(e){e.updateLayout()}function D2(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:s}=e.layout,{animationType:i}=e.options,o=t.source!==e.layout.source;if(i==="size")Rt(f=>{const h=o?t.measuredBox[f]:t.layoutBox[f],y=Ge(h);h.min=r[f].min,h.max=h.min+y});else if(i==="x"||i==="y"){const f=i==="x"?"y":"x";Au(o?t.measuredBox[f]:t.layoutBox[f],r[f])}else Oy(i,t.layoutBox,r)&&Rt(f=>{const h=o?t.measuredBox[f]:t.layoutBox[f],y=Ge(r[f]);h.max=h.min+y,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+y)});const a=wr();js(a,r,t.layoutBox);const u=wr();o?js(u,e.applyTransform(s,!0),t.measuredBox):js(u,r,t.layoutBox);const c=!Dy(a);let d=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:h,layout:y}=f;if(h&&y){const x=e.options.layoutAnchor||void 0,w=Te();Io(w,t.layoutBox,h.layoutBox,x);const b=Te();Io(b,r,y.layoutBox,x),Ry(w,b)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=b,e.relativeTargetOrigin=w,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:u,layoutDelta:a,hasLayoutChanged:c,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function R2(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function I2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function V2(e){e.clearSnapshot()}function Bh(e){e.clearMeasurements()}function F2(e){e.isLayoutDirty=!0,e.updateLayout()}function Hh(e){e.isLayoutDirty=!1}function O2(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function z2(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function $h(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function B2(e){e.resolveTargetDelta()}function H2(e){e.calcProjection()}function $2(e){e.resetSkewAndRotation()}function U2(e){e.removeLeadSnapshot()}function Uh(e,t,n){e.translate=le(t.translate,0,n),e.scale=le(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Wh(e,t,n,r){e.min=le(t.min,n.min,r),e.max=le(t.max,n.max,r)}function W2(e,t,n,r){Wh(e.x,t.x,n.x,r),Wh(e.y,t.y,n.y,r)}function G2(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const K2={duration:.45,ease:[.4,0,.1,1]},Gh=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Kh=Gh("applewebkit/")&&!Gh("chrome/")?Math.round:tt;function qh(e){e.min=Kh(e.min),e.max=Kh(e.max)}function q2(e){qh(e.x),qh(e.y)}function Oy(e,t,n){return e==="position"||e==="preserve-aspect"&&!p2(Ih(t),Ih(n),.2)}function Y2(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const X2=Fy({attachResizeListener:(e,t)=>Ys(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Ja={current:void 0},zy=Fy({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Ja.current){const e=new X2({});e.mount(window),e.setOptions({layoutScroll:!0}),Ja.current=e}return Ja.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Qn=p.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Yh(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Z2(...e){return t=>{let n=!1;const r=e.map(s=>{const i=Yh(s,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let s=0;s{const{width:y,height:x,top:w,left:b,right:m,bottom:g,direction:v}=u.current;if(t||i===!1||!a.current||!y||!x)return;const k=v==="rtl",S=n==="left"?k?`right: ${m}`:`left: ${b}`:k?`left: ${b}`:`right: ${m}`,C=r==="bottom"?`bottom: ${g}`:`top: ${w}`;a.current.dataset.motionPopId=o;const j=document.createElement("style");c&&(j.nonce=c);const P=s??document.head;return P.appendChild(j),j.sheet&&j.sheet.insertRule(` + [data-motion-pop-id="${o}"] { + position: absolute !important; + width: ${y}px !important; + height: ${x}px !important; + ${S}px !important; + ${C}px !important; + } + `),()=>{var M;(M=a.current)==null||M.removeAttribute("data-motion-pop-id"),P.contains(j)&&P.removeChild(j)}},[t]),l.jsx(J2,{isPresent:t,childRef:a,sizeRef:u,pop:i,children:i===!1?e:p.cloneElement(e,{ref:f})})}const tP=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:s,presenceAffectsLayout:i,mode:o,anchorX:a,anchorY:u,root:c})=>{const d=Jt(nP),f=p.useId(),h=p.useRef(n),y=p.useRef(r);ti(()=>{h.current=n,y.current=r});let x=!0,w=p.useMemo(()=>(x=!1,{id:f,initial:t,isPresent:n,custom:s,onExitComplete:b=>{d.set(b,!0);for(const m of d.values())if(!m)return;r&&r()},register:b=>(d.set(b,!1),()=>{var m;d.delete(b),!h.current&&!d.size&&((m=y.current)==null||m.call(y))})}),[n,d,r]);return i&&x&&(w={...w}),p.useMemo(()=>{d.forEach((b,m)=>d.set(m,!1))},[n]),p.useEffect(()=>{!n&&!d.size&&r&&r()},[n]),e=l.jsx(eP,{pop:o==="popLayout",isPresent:n,anchorX:a,anchorY:u,root:c,children:e}),l.jsx(oa.Provider,{value:w,children:e})};function nP(){return new Map}function By(e=!0){const t=p.useContext(oa);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:s}=t,i=p.useId();p.useEffect(()=>{if(e)return s(i)},[e]);const o=p.useCallback(()=>e&&r&&r(i),[i,r,e]);return!n&&r?[!1,o]:[!0]}const Ti=e=>e.key||"";function Xh(e){const t=[];return p.Children.forEach(e,n=>{p.isValidElement(n)&&t.push(n)}),t}const rP=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:s=!0,mode:i="sync",propagate:o=!1,anchorX:a="left",anchorY:u="top",root:c})=>{const[d,f]=By(o),h=p.useMemo(()=>Xh(e),[e]),y=o&&!d?[]:h.map(Ti),x=p.useRef(!0),w=p.useRef(h),b=Jt(()=>new Map),m=p.useRef(new Set),[g,v]=p.useState(h),[k,S]=p.useState(h);ti(()=>{x.current=!1,w.current=h;for(let P=0;P{const M=Ti(P),E=o&&!d?!1:h===k||y.includes(M),O=()=>{if(m.current.has(M))return;if(b.has(M))m.current.add(M),b.set(M,!0);else return;let K=!0;b.forEach(H=>{H||(K=!1)}),K&&(j==null||j(),S(w.current),o&&(f==null||f()),r&&r())};return l.jsx(tP,{isPresent:E,initial:!x.current||n?void 0:!1,custom:t,presenceAffectsLayout:s,mode:i,root:c,onExitComplete:E?void 0:O,anchorX:a,anchorY:u,children:P},M)})})},Hy=p.createContext({strict:!1}),Zh={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Qh=!1;function sP(){if(Qh)return;const e={};for(const t in Zh)e[t]={isEnabled:n=>Zh[t].some(r=>!!n[r])};xy(e),Qh=!0}function $y(){return sP(),BS()}function iP(e){const t=$y();for(const n in e)t[n]={...t[n],...e[n]};xy(t)}const oP=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Vo(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||oP.has(e)}let Uy=e=>!Vo(e);function Wy(e){typeof e=="function"&&(Uy=t=>t.startsWith("on")?!Vo(t):e(t))}try{Wy(require("@emotion/is-prop-valid").default)}catch{}function aP(e,t,n){const r={};for(const s in e)s==="values"&&typeof e.values=="object"||_e(e[s])||(Uy(s)||n===!0&&Vo(s)||!t&&!Vo(s)||e.draggable&&s.startsWith("onDrag"))&&(r[s]=e[s]);return r}function lP({children:e,isValidProp:t,...n}){t&&Wy(t);const r=p.useContext(Qn);n={...r,...n},n.transition=od(n.transition,r.transition),n.isStatic=Jt(()=>n.isStatic);const s=p.useMemo(()=>n,[JSON.stringify(n.transition),n.transformPagePoint,n.reducedMotion,n.skipAnimations]);return l.jsx(Qn.Provider,{value:s,children:e})}const ca=p.createContext({});function uP(e,t){if(ua(e)){const{initial:n,animate:r}=e;return{initial:n===!1||qs(n)?n:void 0,animate:qs(r)?r:void 0}}return e.inherit!==!1?t:{}}function cP(e){const{initial:t,animate:n}=uP(e,p.useContext(ca));return p.useMemo(()=>({initial:t,animate:n}),[Jh(t),Jh(n)])}function Jh(e){return Array.isArray(e)?e.join(" "):e}const vd=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Gy(e,t,n){for(const r in t)!_e(t[r])&&!jy(r,n)&&(e[r]=t[r])}function dP({transformTemplate:e},t){return p.useMemo(()=>{const n=vd();return yd(n,t,e),Object.assign({},n.vars,n.style)},[t])}function fP(e,t){const n=e.style||{},r={};return Gy(r,n,e),Object.assign(r,dP(e,t)),r}function hP(e,t){const n={},r=fP(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const Ky=()=>({...vd(),attrs:{}});function mP(e,t,n,r){const s=p.useMemo(()=>{const i=Ky();return Cy(i,t,Ey(r),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};Gy(i,e.style,e),s.style={...i,...s.style}}return s}const pP=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function wd(e){return typeof e!="string"||e.includes("-")?!1:!!(pP.indexOf(e)>-1||/[A-Z]/u.test(e))}function gP(e,t,n,{latestValues:r},s,i=!1,o){const u=(o??wd(e)?mP:hP)(t,r,s,e),c=aP(t,typeof e=="string",i),d=e!==p.Fragment?{...c,...u,ref:n}:{},{children:f}=t,h=p.useMemo(()=>_e(f)?f.get():f,[f]);return p.createElement(e,{...d,children:h})}function yP({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,s){return{latestValues:xP(n,r,s,e),renderState:t()}}function xP(e,t,n,r){const s={},i=r(e,{});for(const h in i)s[h]=Xi(i[h]);let{initial:o,animate:a}=e;const u=ua(e),c=gy(e);t&&c&&!u&&e.inherit!==!1&&(o===void 0&&(o=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||o===!1;const f=d?a:o;if(f&&typeof f!="boolean"&&!la(f)){const h=Array.isArray(f)?f:[f];for(let y=0;y(t,n)=>{const r=p.useContext(ca),s=p.useContext(oa),i=()=>yP(e,t,r,s);return n?i():Jt(i)},vP=qy({scrapeMotionValuesFromProps:xd,createRenderState:vd}),wP=qy({scrapeMotionValuesFromProps:Ny,createRenderState:Ky}),kP=Symbol.for("motionComponentSymbol");function bP(e,t,n){const r=p.useRef(n);p.useInsertionEffect(()=>{r.current=n});const s=p.useRef(null);return p.useCallback(i=>{var a;i&&((a=e.onMount)==null||a.call(e,i)),t&&(i?t.mount(i):t.unmount());const o=r.current;if(typeof o=="function")if(i){const u=o(i);typeof u=="function"&&(s.current=u)}else s.current?(s.current(),s.current=null):o(i);else o&&(o.current=i)},[t])}const Yy=p.createContext({});function ir(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function SP(e,t,n,r,s,i){var v,k;const{visualElement:o}=p.useContext(ca),a=p.useContext(Hy),u=p.useContext(oa),c=p.useContext(Qn),d=c.reducedMotion,f=c.skipAnimations,h=p.useRef(null),y=p.useRef(!1);r=r||a.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:o,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:d,skipAnimations:f,isSVG:i}),y.current&&h.current&&(h.current.manuallyAnimateOnMount=!0));const x=h.current,w=p.useContext(Yy);x&&!x.projection&&s&&(x.type==="html"||x.type==="svg")&&PP(h.current,n,s,w);const b=p.useRef(!1);p.useInsertionEffect(()=>{x&&b.current&&x.update(n,u)});const m=n[ny],g=p.useRef(!!m&&typeof window<"u"&&!((v=window.MotionHandoffIsComplete)!=null&&v.call(window,m))&&((k=window.MotionHasOptimisedAnimation)==null?void 0:k.call(window,m)));return ti(()=>{y.current=!0,x&&(b.current=!0,window.MotionIsMounted=!0,x.updateFeatures(),x.scheduleRenderMicrotask(),g.current&&x.animationState&&x.animationState.animateChanges())}),p.useEffect(()=>{x&&(!g.current&&x.animationState&&x.animationState.animateChanges(),g.current&&(queueMicrotask(()=>{var S;(S=window.MotionHandoffMarkAsComplete)==null||S.call(window,m)}),g.current=!1),x.enteringChildren=void 0)}),x}function PP(e,t,n,r){const{layoutId:s,layout:i,drag:o,dragConstraints:a,layoutScroll:u,layoutRoot:c,layoutAnchor:d,layoutCrossfade:f}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Xy(e.parent)),e.projection.setOptions({layoutId:s,layout:i,alwaysMeasureLayout:!!o||a&&ir(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:r,crossfade:f,layoutScroll:u,layoutRoot:c,layoutAnchor:d})}function Xy(e){if(e)return e.options.allowProjection!==!1?e.projection:Xy(e.parent)}function el(e,{forwardMotionProps:t=!1,type:n}={},r,s){r&&iP(r);const i=n?n==="svg":wd(e),o=i?wP:vP;function a(c,d){let f;const h={...p.useContext(Qn),...c,layoutId:jP(c)},{isStatic:y}=h,x=cP(c),w=o(c,y);if(!y&&typeof window<"u"){CP();const b=TP(h);f=b.MeasureLayout,x.visualElement=SP(e,w,h,s,b.ProjectionNode,i)}return l.jsxs(ca.Provider,{value:x,children:[f&&x.visualElement?l.jsx(f,{visualElement:x.visualElement,...h}):null,gP(e,c,bP(w,x.visualElement,d),w,y,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const u=p.forwardRef(a);return u[kP]=e,u}function jP({layoutId:e}){const t=p.useContext($c).id;return t&&e!==void 0?t+"-"+e:e}function CP(e,t){p.useContext(Hy).strict}function TP(e){const t=$y(),{drag:n,layout:r}=t;if(!n&&!r)return{};const s={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?s.MeasureLayout:void 0,ProjectionNode:s.ProjectionNode}}function EP(e,t){if(typeof Proxy>"u")return el;const n=new Map,r=(i,o)=>el(i,o,e,t),s=(i,o)=>r(i,o);return new Proxy(s,{get:(i,o)=>o==="create"?r:(n.has(o)||n.set(o,el(o,void 0,e,t)),n.get(o))})}const NP=(e,t)=>t.isSVG??wd(e)?new s2(t):new QS(t,{allowProjection:e!==p.Fragment});class _P extends Mn{constructor(t){super(t),t.animationState||(t.animationState=u2(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();la(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let MP=0;class LP extends Mn{constructor(){super(...arguments),this.id=MP++,this.isExitComplete=!1}update(){var i;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:o,custom:a}=this.node.getProps();if(typeof o=="string"||typeof o=="object"&&o!==null&&!Array.isArray(o)){const u=Wn(this.node,o,a);if(u){const{transition:c,transitionEnd:d,...f}=u;for(const h in f)(i=this.node.getValue(h))==null||i.jump(f[h])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const s=this.node.animationState.setActive("exit",!t);n&&!t&&s.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const AP={animation:{Feature:_P},exit:{Feature:LP}};function ii(e){return{point:{x:e.pageX,y:e.pageY}}}const DP=e=>t=>fd(t)&&e(t,ii(t));function Cs(e,t,n,r){return Ys(e,t,DP(n),r)}const Zy=({current:e})=>e?e.ownerDocument.defaultView:null,em=(e,t)=>Math.abs(e-t);function RP(e,t){const n=em(e.x,t.x),r=em(e.y,t.y);return Math.sqrt(n**2+r**2)}const tm=new Set(["auto","scroll"]);class Qy{constructor(t,n,{transformPagePoint:r,contextWindow:s=window,dragSnapToOrigin:i=!1,distanceThreshold:o=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=x=>{this.handleScroll(x.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Ei(this.lastRawMoveEventInfo,this.transformPagePoint));const x=tl(this.lastMoveEventInfo,this.history),w=this.startEvent!==null,b=RP(x.offset,{x:0,y:0})>=this.distanceThreshold;if(!w&&!b)return;const{point:m}=x,{timestamp:g}=Me;this.history.push({...m,timestamp:g});const{onStart:v,onMove:k}=this.handlers;w||(v&&v(this.lastMoveEvent,x),this.startEvent=this.lastMoveEvent),k&&k(this.lastMoveEvent,x)},this.handlePointerMove=(x,w)=>{this.lastMoveEvent=x,this.lastRawMoveEventInfo=w,this.lastMoveEventInfo=Ei(w,this.transformPagePoint),Z.update(this.updatePoint,!0)},this.handlePointerUp=(x,w)=>{this.end();const{onEnd:b,onSessionEnd:m,resumeAnimation:g}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&g&&g(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=tl(x.type==="pointercancel"?this.lastMoveEventInfo:Ei(w,this.transformPagePoint),this.history);this.startEvent&&b&&b(x,v),m&&m(x,v)},!fd(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=s||window;const u=ii(t),c=Ei(u,this.transformPagePoint),{point:d}=c,{timestamp:f}=Me;this.history=[{...d,timestamp:f}];const{onSessionStart:h}=n;h&&h(t,tl(c,this.history));const y={passive:!0,capture:!0};this.removeListeners=ni(Cs(this.contextWindow,"pointermove",this.handlePointerMove,y),Cs(this.contextWindow,"pointerup",this.handlePointerUp,y),Cs(this.contextWindow,"pointercancel",this.handlePointerUp,y)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(tm.has(r.overflowX)||tm.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,s=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:s.x-n.x,y:s.y-n.y};i.x===0&&i.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(t,s),Z.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),vt(this.updatePoint)}}function Ei(e,t){return t?{point:t(e.point)}:e}function nm(e,t){return{x:e.x-t.x,y:e.y-t.y}}function tl({point:e},t){return{point:e,delta:nm(e,Jy(t)),offset:nm(e,IP(t)),velocity:VP(t,.1)}}function IP(e){return e[0]}function Jy(e){return e[e.length-1]}function VP(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const s=Jy(e);for(;n>=0&&(r=e[n],!(s.timestamp-r.timestamp>at(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&s.timestamp-r.timestamp>at(t)*2&&(r=e[1]);const i=pt(s.timestamp-r.timestamp);if(i===0)return{x:0,y:0};const o={x:(s.x-r.x)/i,y:(s.y-r.y)/i};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function FP(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?le(n,e,r.max):Math.min(e,n)),e}function rm(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function OP(e,{top:t,left:n,bottom:r,right:s}){return{x:rm(e.x,n,s),y:rm(e.y,t,r)}}function sm(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=Ir(t.min,t.max-r,e.min):r>s&&(n=Ir(e.min,e.max-s,t.min)),Mt(0,1,n)}function HP(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Du=.35;function $P(e=Du){return e===!1?e=0:e===!0&&(e=Du),{x:im(e,"left","right"),y:im(e,"top","bottom")}}function im(e,t,n){return{min:om(e,t),max:om(e,n)}}function om(e,t){return typeof e=="number"?e:e[t]||0}const UP=new WeakMap;class WP{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Te(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:s}=this.visualElement;if(s&&s.isPresent===!1)return;const i=f=>{n&&this.snapToCursor(ii(f).point),this.stopAnimation()},o=(f,h)=>{const{drag:y,dragPropagation:x,onDragStart:w}=this.getProps();if(y&&!x&&(this.openDragLock&&this.openDragLock(),this.openDragLock=gS(y),!this.openDragLock))return;this.latestPointerEvent=f,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Rt(m=>{let g=this.getAxisMotionValue(m).get()||0;if(zt.test(g)){const{projection:v}=this.visualElement;if(v&&v.layout){const k=v.layout.layoutBox[m];k&&(g=Ge(k)*(parseFloat(g)/100))}}this.originPoint[m]=g}),w&&Z.update(()=>w(f,h),!1,!0),Pu(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(f,h)=>{this.latestPointerEvent=f,this.latestPanInfo=h;const{dragPropagation:y,dragDirectionLock:x,onDirectionLock:w,onDrag:b}=this.getProps();if(!y&&!this.openDragLock)return;const{offset:m}=h;if(x&&this.currentDirection===null){this.currentDirection=KP(m),this.currentDirection!==null&&w&&w(this.currentDirection);return}this.updateAxis("x",h.point,m),this.updateAxis("y",h.point,m),this.visualElement.render(),b&&Z.update(()=>b(f,h),!1,!0)},u=(f,h)=>{this.latestPointerEvent=f,this.latestPanInfo=h,this.stop(f,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>{const{dragSnapToOrigin:f}=this.getProps();(f||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:d}=this.getProps();this.panSession=new Qy(t,{onSessionStart:i,onStart:o,onMove:a,onSessionEnd:u,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:r,contextWindow:Zy(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,s=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!s||!r)return;const{velocity:o}=s;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&Z.postRender(()=>a(r,s))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:s}=this.getProps();if(!r||!Ni(t,s,this.currentDirection))return;const i=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=FP(o,this.constraints[t],this.elastic[t])),i.set(o)}resolveConstraints(){var i;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(i=this.visualElement.projection)==null?void 0:i.layout,s=this.constraints;t&&ir(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=OP(r.layoutBox,t):this.constraints=!1,this.elastic=$P(n),s!==this.constraints&&!ir(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Rt(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=HP(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!ir(t))return!1;const r=t.current,{projection:s}=this.visualElement;if(!s||!s.layout)return!1;s.root&&(s.root.scroll=void 0,s.root.updateScroll());const i=GS(r,s.root,this.visualElement.getTransformPagePoint());let o=zP(s.layout.layoutBox,i);if(n){const a=n($S(o));this.hasMutatedConstraints=!!a,a&&(o=wy(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:s,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),u=this.constraints||{},c=Rt(d=>{if(!Ni(d,n,this.currentDirection))return;let f=u&&u[d]||{};(o===!0||o===d)&&(f={min:0,max:0});const h=s?200:1e6,y=s?40:1e7,x={type:"inertia",velocity:r?t[d]:0,bounceStiffness:h,bounceDamping:y,timeConstant:750,restDelta:1,restSpeed:10,...i,...f};return this.startAxisValueAnimation(d,x)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Pu(this.visualElement,t),r.start(ld(t,r,0,n,this.visualElement,!1))}stopAnimation(){Rt(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,s=this.visualElement.getProps()[n];return s||this.visualElement.getValue(t,this.visualElement.latestValues[t]??0)}snapToCursor(t){Rt(n=>{const{drag:r}=this.getProps();if(!Ni(n,r,this.currentDirection))return;const{projection:s}=this.visualElement,i=this.getAxisMotionValue(n);if(s&&s.layout){const{min:o,max:a}=s.layout.layoutBox[n],u=i.get()||0;i.set(t[n]-le(o,a,.5)+u)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!ir(n)||!r||!this.constraints)return;this.stopAnimation();const s={x:0,y:0};Rt(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const u=a.get();s[o]=BP({min:u,max:u},this.constraints[o])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),Rt(o=>{if(!Ni(o,t,null))return;const a=this.getAxisMotionValue(o),{min:u,max:c}=this.constraints[o];a.set(le(u,c,s[o]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;UP.set(this.visualElement,this);const t=this.visualElement.current,n=Cs(t,"pointerdown",c=>{const{drag:d,dragListener:f=!0}=this.getProps(),h=c.target,y=h!==t&&bS(h);d&&f&&!y&&this.start(c)});let r;const s=()=>{const{dragConstraints:c}=this.getProps();ir(c)&&c.current&&(this.constraints=this.resolveRefConstraints(),r||(r=GP(t,c.current,()=>this.scalePositionWithinConstraints())))},{projection:i}=this.visualElement,o=i.addEventListener("measure",s);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),Z.read(s);const a=Ys(window,"resize",()=>this.scalePositionWithinConstraints()),u=i.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d})=>{this.isDragging&&d&&(Rt(f=>{const h=this.getAxisMotionValue(f);h&&(this.originPoint[f]+=c[f].translate,h.set(h.get()+c[f].translate))}),this.visualElement.render())});return()=>{a(),n(),o(),u&&u(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:s=!1,dragConstraints:i=!1,dragElastic:o=Du,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:s,dragConstraints:i,dragElastic:o,dragMomentum:a}}}function am(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function GP(e,t,n){const r=Nu(e,am(n)),s=Nu(t,am(n));return()=>{r(),s()}}function Ni(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function KP(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class qP extends Mn{constructor(t){super(t),this.removeGroupControls=tt,this.removeListeners=tt,this.controls=new WP(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||tt}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const nl=e=>(t,n)=>{e&&Z.update(()=>e(t,n),!1,!0)};class YP extends Mn{constructor(){super(...arguments),this.removePointerDownListener=tt}onPointerDown(t){this.session=new Qy(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Zy(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:s}=this.node.getProps();return{onSessionStart:nl(t),onStart:nl(n),onMove:nl(r),onEnd:(i,o)=>{delete this.session,s&&Z.postRender(()=>s(i,o))}}}mount(){this.removePointerDownListener=Cs(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let rl=!1;class XP extends p.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:s}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),r&&r.register&&s&&r.register(i),rl&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),Zi.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:s,isPresent:i}=this.props,{projection:o}=r;return o&&(o.isPresent=i,t.layoutDependency!==n&&o.setOptions({...o.options,layoutDependency:n}),rl=!0,s||t.layoutDependency!==n||n===void 0||t.isPresent!==i?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||Z.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),Fr.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:s}=t;rl=!0,s&&(s.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(s),r&&r.deregister&&r.deregister(s))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function ex(e){const[t,n]=By(),r=p.useContext($c);return l.jsx(XP,{...e,layoutGroup:r,switchLayoutGroup:p.useContext(Yy),isPresent:t,safeToRemove:n})}const ZP={pan:{Feature:YP},drag:{Feature:qP,ProjectionNode:zy,MeasureLayout:ex}};function lm(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const s="onHover"+n,i=r[s];i&&Z.postRender(()=>i(t,ii(t)))}class QP extends Mn{mount(){const{current:t}=this.node;t&&(this.unmount=xS(t,(n,r)=>(lm(this.node,r,"Start"),s=>lm(this.node,s,"End"))))}unmount(){}}class JP extends Mn{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=ni(Ys(this.node.current,"focus",()=>this.onFocus()),Ys(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function um(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const s="onTap"+(n==="End"?"":n),i=r[s];i&&Z.postRender(()=>i(t,ii(t)))}class ej extends Mn{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=PS(t,(s,i)=>(um(this.node,i,"Start"),(o,{success:a})=>um(this.node,o,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const Ru=new WeakMap,sl=new WeakMap,tj=e=>{const t=Ru.get(e.target);t&&t(e)},nj=e=>{e.forEach(tj)};function rj({root:e,...t}){const n=e||document;sl.has(n)||sl.set(n,{});const r=sl.get(n),s=JSON.stringify(t);return r[s]||(r[s]=new IntersectionObserver(nj,{root:e,...t})),r[s]}function sj(e,t,n){const r=rj(t);return Ru.set(e,n),r.observe(e),()=>{Ru.delete(e),r.unobserve(e)}}const ij={some:0,all:1};class oj extends Mn{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var u;(u=this.stopObserver)==null||u.call(this);const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:s="some",once:i}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof s=="number"?s:ij[s]},a=c=>{const{isIntersecting:d}=c;if(this.isInView===d||(this.isInView=d,i&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:f,onViewportLeave:h}=this.node.getProps(),y=d?f:h;y&&y(c)};this.stopObserver=sj(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(aj(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function aj({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const lj={inView:{Feature:oj},tap:{Feature:ej},focus:{Feature:JP},hover:{Feature:QP}},uj={layout:{ProjectionNode:zy,MeasureLayout:ex}},cj={...AP,...lj,...ZP,...uj},Kt=EP(cj,NP);function Fo(e){return typeof window>"u"?!1:e?G0():id()}const dj=50,cm=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),fj=()=>({time:0,x:cm(),y:cm()}),hj={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function dm(e,t,n,r){const s=n[t],{length:i,position:o}=hj[t],a=s.current,u=n.time;s.current=Math.abs(e[`scroll${o}`]),s.scrollLength=e[`scroll${i}`]-e[`client${i}`],s.offset.length=0,s.offset[0]=0,s.offset[1]=s.scrollLength,s.progress=Ir(0,s.scrollLength,s.current);const c=r-u;s.velocity=c>dj?0:Kc(s.current-a,c)}function mj(e,t,n){dm(e,"x",t,n),dm(e,"y",t,n),t.time=n}function pj(e,t){const n={x:0,y:0};let r=e;for(;r&&r!==t;)if(Ps(r))n.x+=r.offsetLeft,n.y+=r.offsetTop,r=r.offsetParent;else if(r.tagName==="svg"){const s=r.getBoundingClientRect();r=r.parentElement;const i=r.getBoundingClientRect();n.x+=s.left-i.left,n.y+=s.top-i.top}else if(r instanceof SVGGraphicsElement){const{x:s,y:i}=r.getBBox();n.x+=s,n.y+=i;let o=null,a=r.parentNode;for(;!o;)a.tagName==="svg"&&(o=a),a=r.parentNode;r=o}else break;return n}const Iu={start:0,center:.5,end:1};function fm(e,t,n=0){let r=0;if(e in Iu&&(e=Iu[e]),typeof e=="string"){const s=parseFloat(e);e.endsWith("px")?r=s:e.endsWith("%")?e=s/100:e.endsWith("vw")?r=s/100*document.documentElement.clientWidth:e.endsWith("vh")?r=s/100*document.documentElement.clientHeight:e=s}return typeof e=="number"&&(r=t*e),n+r}const gj=[0,0];function yj(e,t,n,r){let s=Array.isArray(e)?e:gj,i=0,o=0;return typeof e=="number"?s=[e,e]:typeof e=="string"&&(e=e.trim(),e.includes(" ")?s=e.split(" "):s=[e,Iu[e]?e:"0"]),i=fm(s[0],n,r),o=fm(s[1],t),i-o}const ds={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]},xj={x:0,y:0};function vj(e){return"getBBox"in e&&e.tagName!=="svg"?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function wj(e,t,n){const{offset:r=ds.All}=n,{target:s=e,axis:i="y"}=n,o=i==="y"?"height":"width",a=s!==e?pj(s,e):xj,u=s===e?{width:e.scrollWidth,height:e.scrollHeight}:vj(s),c={width:e.clientWidth,height:e.clientHeight};t[i].offset.length=0;let d=!t[i].interpolate;const f=r.length;for(let h=0;h{kj(e,r.target,n),mj(e,n,s),(r.offset||r.target)&&wj(e,n,r)},notify:()=>t(n)}}const sr=new WeakMap,hm=new WeakMap,il=new WeakMap,mm=new WeakMap,_i=new WeakMap,pm=e=>e===document.scrollingElement?window:e;function tx(e,{container:t=document.scrollingElement,trackContentSize:n=!1,...r}={}){if(!t)return tt;let s=il.get(t);s||(s=new Set,il.set(t,s));const i=fj(),o=bj(t,e,i,r);if(s.add(o),!sr.has(t)){const u=()=>{for(const h of s)h.measure(Me.timestamp);Z.preUpdate(c)},c=()=>{for(const h of s)h.notify()},d=()=>Z.read(u);sr.set(t,d);const f=pm(t);window.addEventListener("resize",d),t!==document.documentElement&&hm.set(t,Nu(t,d)),f.addEventListener("scroll",d),d()}if(n&&!_i.has(t)){const u=sr.get(t),c={width:t.scrollWidth,height:t.scrollHeight};mm.set(t,c);const d=()=>{const h=t.scrollWidth,y=t.scrollHeight;(c.width!==h||c.height!==y)&&(u(),c.width=h,c.height=y)},f=Z.read(d,!0);_i.set(t,f)}const a=sr.get(t);return Z.read(a,!1,!0),()=>{var f;vt(a);const u=il.get(t);if(!u||(u.delete(o),u.size))return;const c=sr.get(t);sr.delete(t),c&&(pm(t).removeEventListener("scroll",c),(f=hm.get(t))==null||f(),window.removeEventListener("resize",c));const d=_i.get(t);d&&(vt(d),_i.delete(t)),mm.delete(t)}}const Sj=[[ds.Enter,"entry"],[ds.Exit,"exit"],[ds.Any,"cover"],[ds.All,"contain"]],gm={start:0,end:1};function Pj(e){const t=e.trim().split(/\s+/);if(t.length!==2)return;const n=gm[t[0]],r=gm[t[1]];if(!(n===void 0||r===void 0))return[n,r]}function jj(e){if(e.length!==2)return;const t=[];for(const n of e)if(Array.isArray(n))t.push(n);else if(typeof n=="string"){const r=Pj(n);if(!r)return;t.push(r)}else return;return t}function Cj(e,t){const n=jj(e);if(!n)return!1;for(let r=0;r<2;r++){const s=n[r],i=t[r];if(s[0]!==i[0]||s[1]!==i[1])return!1}return!0}function kd(e){if(!e)return{rangeStart:"contain 0%",rangeEnd:"contain 100%"};for(const[t,n]of Sj)if(Cj(e,t))return{rangeStart:`${n} 0%`,rangeEnd:`${n} 100%`}}const ym=new Map;function xm(e){const t={value:0},n=tx(r=>{t.value=r[e.axis].progress*100},e);return{currentTime:t,cancel:n}}function nx({source:e,container:t,...n}){const{axis:r}=n;e&&(t=e);let s=ym.get(t);s||(s=new Map,ym.set(t,s));const i=n.target??"self";let o=s.get(i);o||(o={},s.set(i,o));const a=r+(n.offset??[]).join(",");return o[a]||(n.target&&Fo(n.target)?kd(n.offset)?o[a]=new ViewTimeline({subject:n.target,axis:r}):o[a]=xm({container:t,...n}):Fo()?o[a]=new ScrollTimeline({source:t,axis:r}):o[a]=xm({container:t,...n})),o[a]}function Tj(e,t){const n=nx(t),r=t.target?kd(t.offset):void 0,s=t.target?Fo(t.target)&&!!r:Fo();return e.attachTimeline({timeline:s?n:void 0,...r&&s&&{rangeStart:r.rangeStart,rangeEnd:r.rangeEnd},observe:i=>(i.pause(),py(o=>{i.time=i.iterationDuration*o},n))})}function Ej(e){return e&&(e.target||e.offset)}function Nj(e){return e.length===2}function _j(e,t){return Nj(e)||Ej(t)?tx(n=>{e(n[t.axis].progress,n)},t):py(e,nx(t))}function rx(e,{axis:t="y",container:n=document.scrollingElement,...r}={}){if(!n)return tt;const s={axis:t,container:n,...r};return typeof e=="function"?_j(e,s):Tj(e,s)}const Mj=()=>({scrollX:Ct(0),scrollY:Ct(0),scrollXProgress:Ct(0),scrollYProgress:Ct(0)}),kr=e=>e?!e.current:!1;function vm(e,t,n,r){return{factory:s=>{let i;const o=()=>{if(kr(n)||kr(r)){Fr.read(o);return}i=rx(s,{...t,axis:e,container:(n==null?void 0:n.current)||void 0,target:(r==null?void 0:r.current)||void 0})};return Fr.read(o),()=>{cy(o),i==null||i()}},times:[0,1],keyframes:[0,1],ease:s=>s,duration:1}}function Lj(e,t){return typeof window>"u"?!1:e?G0()&&!!kd(t):id()}function sx({container:e,target:t,...n}={}){const r=Jt(Mj);Lj(t,n.offset)&&(r.scrollXProgress.accelerate=vm("x",n,e,t),r.scrollYProgress.accelerate=vm("y",n,e,t));const s=p.useRef(null),i=p.useRef(!1),o=p.useCallback(()=>(s.current=rx((a,{x:u,y:c})=>{r.scrollX.set(u.current),r.scrollXProgress.set(u.progress),r.scrollY.set(c.current),r.scrollYProgress.set(c.progress)},{...n,container:(e==null?void 0:e.current)||void 0,target:(t==null?void 0:t.current)||void 0}),()=>{var a;(a=s.current)==null||a.call(s)}),[e,t,JSON.stringify(n.offset)]);return ti(()=>{if(i.current=!1,kr(e)||kr(t)){i.current=!0;return}else return o()},[o]),p.useEffect(()=>{if(!i.current)return;let a;const u=()=>{const c=kr(e),d=kr(t);!c&&!d&&(a=o())};return Fr.read(u),()=>{cy(u),a==null||a()}},[o]),r}function ix(e){const t=Jt(()=>Ct(e)),{isStatic:n}=p.useContext(Qn);if(n){const[,r]=p.useState(e);p.useEffect(()=>t.on("change",r),[])}return t}function ox(e,t){const n=ix(t()),r=()=>n.set(t());return r(),ti(()=>{const s=()=>Z.preRender(r,!1,!0),i=e.map(o=>o.on("change",s));return()=>{i.forEach(o=>o()),vt(r)}}),n}function Aj(e){Ss.current=[],e();const t=ox(Ss.current,e);return Ss.current=void 0,t}function an(e,t,n,r){if(typeof e=="function")return Aj(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!="function")return Dj(e,t,n,r);const o=typeof t=="function"?t:DS(t,n,r),a=Array.isArray(e)?wm(e,o):wm([e],([c])=>o(c)),u=Array.isArray(e)?void 0:e.accelerate;return u&&!u.isTransformed&&typeof t!="function"&&Array.isArray(n)&&(r==null?void 0:r.clamp)!==!1&&(a.accelerate={...u,times:t,keyframes:n,isTransformed:!0}),a}function wm(e,t){const n=Jt(()=>[]);return ox(e,()=>{n.length=0;const r=e.length;for(let s=0;sObject.keys(n)),i=Jt(()=>({}));for(const o of s)i[o]=an(e,t,n[o],r);return i}function Rj(e,t={}){const{isStatic:n}=p.useContext(Qn),r=()=>_e(e)?e.get():e;if(n)return an(r);const s=ix(r());return p.useInsertionEffect(()=>RS(s,e,t),[s,JSON.stringify(t)]),s}function Ij(e,t={}){return Rj(e,{type:"spring",...t})}function Vj(){!gd.current&&yy();const[e]=p.useState(Ao.current);return e}function Fj(){const{pathname:e}=nt();return p.useEffect(()=>{window.scrollTo({top:0,left:0,behavior:"instant"})},[e]),null}const Oj='a, button, [role="button"], label, select, summary, [data-cursor="hover"], .cursor-pointer',zj='input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="submit"]):not([type="button"]):not([type="file"]), textarea, [contenteditable="true"]';function Bj(){const e=p.useRef(null),t=p.useRef(null),n=p.useRef(null),r=p.useRef(null),s=p.useRef(null);return p.useEffect(()=>{const i=window.matchMedia("(pointer: fine)"),o=window.matchMedia("(prefers-reduced-motion: reduce)");if(!i.matches||o.matches)return;const a=e.current,u=t.current,c=n.current,d=r.current,f=s.current;if(!a||!u||!c||!d||!f)return;document.documentElement.classList.add("hifi-cursor-on");const h=-24*Math.PI/180,y=Math.cos(h),x=Math.sin(h);let w=-100,b=-100,m=0,g=2.4,v=2.4,k=16,S=6.5,C=16,j=6.5,P=!1,M,E=performance.now();const O=N=>{const L=Math.min((N-E)/1e3,.05);E=N,g+=(v-g)*Math.min(1,L*8),k+=(C-k)*Math.min(1,L*10),S+=(j-S)*Math.min(1,L*10),m+=g*L,u.style.transform=`translate3d(${w}px, ${b}px, 0)`,c.style.transform=`translate3d(${w}px, ${b}px, 0)`;const F=Math.cos(m)*k,T=Math.sin(m)*S;d.style.transform=`translate(${F*y-T*x}px, ${F*x+T*y}px)`,M=requestAnimationFrame(O)},K=N=>{a.dataset.state=N;const L=N==="hover";v=L?7:2.4,C=L?23:16,j=L?9.5:6.5},H=N=>{w=N.clientX,b=N.clientY,P||(P=!0,a.dataset.hidden="false")},$=N=>{const L=N.target;L instanceof Element&&(L.closest(zj)?K("text"):L.closest(Oj)?K("hover"):K("default"))},se=()=>{a.dataset.down="true",f.style.left=`${w}px`,f.style.top=`${b}px`,f.classList.remove("is-live"),f.offsetWidth,f.classList.add("is-live")},G=()=>{a.dataset.down="false"},X=()=>{P=!1,a.dataset.hidden="true"};return document.addEventListener("mousemove",H,{passive:!0}),document.addEventListener("mouseover",$,{passive:!0}),document.addEventListener("mousedown",se,{passive:!0}),document.addEventListener("mouseup",G,{passive:!0}),document.documentElement.addEventListener("mouseleave",X),window.addEventListener("blur",X),M=requestAnimationFrame(O),()=>{cancelAnimationFrame(M),document.removeEventListener("mousemove",H),document.removeEventListener("mouseover",$),document.removeEventListener("mousedown",se),document.removeEventListener("mouseup",G),document.documentElement.removeEventListener("mouseleave",X),window.removeEventListener("blur",X),document.documentElement.classList.remove("hifi-cursor-on")}},[]),l.jsxs("div",{ref:e,className:"hifi-cursor","data-state":"default","data-hidden":"true","data-down":"false","aria-hidden":"true",children:[l.jsxs("div",{ref:n,className:"hifi-cursor__orbit",children:[l.jsx("div",{className:"hifi-cursor__ring"}),l.jsx("div",{ref:r,className:"hifi-cursor__sat"})]}),l.jsx("div",{ref:t,className:"hifi-cursor__core"}),l.jsx("div",{ref:s,className:"hifi-cursor__pulse"})]})}const Hj=`${"/".replace(/\/$/,"")}/api`;let Vu=0;const Fu=new Set,km=e=>{Vu+=e,Fu.forEach(t=>t(Vu))},$j=()=>Vu,Uj=e=>(Fu.add(e),()=>Fu.delete(e)),Ou=new Set,Wj=e=>(Ou.add(e),()=>Ou.delete(e));async function is(e,t={}){km(1);try{return await Gj(e,t)}finally{km(-1)}}async function Gj(e,t){const n=await fetch(`${Hj}${e}`,{credentials:"include",headers:t.body instanceof FormData?{}:{"Content-Type":"application/json"},...t}),r=await n.text();let s=null;if(r)try{s=JSON.parse(r)}catch{}if(!n.ok){const i=new Error((s==null?void 0:s.error)||`Fehler ${n.status}`);throw i.status=n.status,i.code=(s==null?void 0:s.code)||null,n.status===401&&!e.startsWith("/auth/")&&Ou.forEach(o=>o()),i}if(s===null&&r){const i=new Error("Unerwartete Server-Antwort (kein gültiges JSON)");throw i.status=n.status,i.code="invalid_response",i}return s}const ce={get:(e,t)=>is(e,t),post:(e,t)=>is(e,{method:"POST",body:t instanceof FormData?t:JSON.stringify(t)}),put:(e,t)=>is(e,{method:"PUT",body:JSON.stringify(t)}),patch:(e,t)=>is(e,{method:"PATCH",body:JSON.stringify(t)}),delete:e=>is(e,{method:"DELETE"})};function Kj({children:e}){const[t,n]=p.useState({pathname:null,needsSetup:null}),r=nt(),s=t.needsSetup===!1;p.useEffect(()=>{if(s)return;let o=!1;return ce.get("/setup/status").then(a=>{o||n({pathname:r.pathname,needsSetup:a.needs_setup})}).catch(()=>{o||n({pathname:r.pathname,needsSetup:!1})}),()=>{o=!0}},[r.pathname,s]);const i=t.pathname===r.pathname;return r.pathname==="/setup"?s?l.jsx(Zn,{to:"/",replace:!0}):!i||t.needsSetup===null?l.jsx("div",{className:"min-h-screen bg-white dark:bg-neutral-950"}):e:i&&t.needsSetup?l.jsx(Zn,{to:"/setup",replace:!0}):e}/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ax=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const qj=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Yj=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase());/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const bm=e=>{const t=Yj(e);return t.charAt(0).toUpperCase()+t.slice(1)};/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */var ol={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Xj=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0;return!1},lx=p.createContext({});function _N({children:e,size:t,color:n,strokeWidth:r,absoluteStrokeWidth:s,className:i}){const o=p.useMemo(()=>({size:t,color:n,strokeWidth:r,absoluteStrokeWidth:s,className:i}),[t,n,r,s,i]);return p.createElement(lx.Provider,{value:o},e)}const Zj=()=>p.useContext(lx),Qj=p.forwardRef(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:r,className:s="",children:i,iconNode:o,...a},u)=>{const{size:c=24,strokeWidth:d=2,absoluteStrokeWidth:f=!1,color:h="currentColor",className:y=""}=Zj()??{},x=r??f?Number(n??d)*24/Number(t??c):n??d;return p.createElement("svg",{ref:u,...ol,width:t??c??ol.width,height:t??c??ol.height,stroke:e??h,strokeWidth:x,className:ax("lucide",y,s),...!i&&!Xj(a)&&{"aria-hidden":"true"},...a},[...o.map(([w,b])=>p.createElement(w,b)),...Array.isArray(i)?i:[i]])});/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ee=(e,t)=>{const n=p.forwardRef(({className:r,...s},i)=>p.createElement(Qj,{ref:i,iconNode:t,className:ax(`lucide-${qj(bm(e))}`,`lucide-${e}`,r),...s}));return n.displayName=bm(e),n};/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const Jj=[["path",{d:"M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z",key:"lc1i9w"}],["path",{d:"m7 16.5-4.74-2.85",key:"1o9zyk"}],["path",{d:"m7 16.5 5-3",key:"va8pkn"}],["path",{d:"M7 16.5v5.17",key:"jnp8gn"}],["path",{d:"M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z",key:"8zsnat"}],["path",{d:"m17 16.5-5-3",key:"8arw3v"}],["path",{d:"m17 16.5 4.74-2.85",key:"8rfmw"}],["path",{d:"M17 16.5v5.17",key:"k6z78m"}],["path",{d:"M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z",key:"1xygjf"}],["path",{d:"M12 8 7.26 5.15",key:"1vbdud"}],["path",{d:"m12 8 4.74-2.85",key:"3rx089"}],["path",{d:"M12 13.5V8",key:"1io7kd"}]],eC=ee("boxes",Jj);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const tC=[["path",{d:"m21 8-2 2-1.5-3.7A2 2 0 0 0 15.646 5H8.4a2 2 0 0 0-1.903 1.257L5 10 3 8",key:"1imjwt"}],["path",{d:"M7 14h.01",key:"1qa3f1"}],["path",{d:"M17 14h.01",key:"7oqj8z"}],["rect",{width:"18",height:"8",x:"3",y:"10",rx:"2",key:"a7itu8"}],["path",{d:"M5 18v2",key:"ppbyun"}],["path",{d:"M19 18v2",key:"gy7782"}]],nC=ee("car-front",tC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const rC=[["path",{d:"M19 17h2c.6 0 1-.4 1-1v-3c0-.9-.7-1.7-1.5-1.9C18.7 10.6 16 10 16 10s-1.3-1.4-2.2-2.3c-.5-.4-1.1-.7-1.8-.7H5c-.6 0-1.1.4-1.4.9l-1.4 2.9A3.7 3.7 0 0 0 2 12v4c0 .6.4 1 1 1h2",key:"5owen"}],["circle",{cx:"7",cy:"17",r:"2",key:"u2ysq9"}],["path",{d:"M9 17h6",key:"r8uit2"}],["circle",{cx:"17",cy:"17",r:"2",key:"axvx0g"}]],Oo=ee("car",rC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const sC=[["path",{d:"M18 19V9a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v8a2 2 0 0 0 2 2h2",key:"19jm3t"}],["path",{d:"M2 9h3a1 1 0 0 1 1 1v2a1 1 0 0 1-1 1H2",key:"13hakp"}],["path",{d:"M22 17v1a1 1 0 0 1-1 1H10v-9a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v9",key:"1crci8"}],["circle",{cx:"8",cy:"19",r:"2",key:"t8fc5s"}]],iC=ee("caravan",sC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const oC=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],aC=ee("check",oC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const lC=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],uC=ee("chevron-down",lC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const cC=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],dC=ee("chevron-left",cC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const fC=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],hC=ee("chevron-right",fC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const mC=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],pC=ee("chevron-up",mC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const gC=[["path",{d:"M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z",key:"kmsa83"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],yC=ee("circle-play",gC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const xC=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]],ux=ee("clock",xC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const vC=[["path",{d:"M11 10.27 7 3.34",key:"16pf9h"}],["path",{d:"m11 13.73-4 6.93",key:"794ttg"}],["path",{d:"M12 22v-2",key:"1osdcq"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M14 12h8",key:"4f43i9"}],["path",{d:"m17 20.66-1-1.73",key:"eq3orb"}],["path",{d:"m17 3.34-1 1.73",key:"2wel8s"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"m20.66 17-1.73-1",key:"sg0v6f"}],["path",{d:"m20.66 7-1.73 1",key:"1ow05n"}],["path",{d:"m3.34 17 1.73-1",key:"nuk764"}],["path",{d:"m3.34 7 1.73 1",key:"1ulond"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["circle",{cx:"12",cy:"12",r:"8",key:"46899m"}]],wC=ee("cog",vC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const kC=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],bC=ee("external-link",kC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const SC=[["path",{d:"M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4",key:"1slcih"}]],PC=ee("flame",SC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const jC=[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]],CC=ee("layout-dashboard",jC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const TC=[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]],EC=ee("lightbulb",TC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const NC=[["path",{d:"m10 17 5-5-5-5",key:"1bsop3"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}]],_C=ee("log-in",NC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const MC=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],zu=ee("mail",MC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const LC=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],cx=ee("map-pin",LC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const AC=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],dx=ee("message-circle",AC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const DC=[["rect",{x:"5",y:"2",width:"14",height:"20",rx:"7",key:"11ol66"}],["path",{d:"M12 6v4",key:"16clxf"}]],RC=ee("mouse",DC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const IC=[["polygon",{points:"3 11 22 2 13 21 11 13 3 11",key:"1ltx0t"}]],VC=ee("navigation",IC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const FC=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]],OC=ee("package",FC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const zC=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],Or=ee("phone",zC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const BC=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],HC=ee("send",BC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const $C=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]],UC=ee("shield-alert",$C);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const WC=[["path",{d:"M16 10a4 4 0 0 1-8 0",key:"1ltviw"}],["path",{d:"M3.103 6.034h17.794",key:"awc11p"}],["path",{d:"M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z",key:"o988cm"}]],GC=ee("shopping-bag",WC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const KC=[["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z",key:"emmmcr"}],["path",{d:"M7 10v12",key:"1qc93n"}]],qC=ee("thumbs-up",KC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const YC=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],XC=ee("user",YC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ZC=[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]],QC=ee("video",ZC);/** + * @license lucide-react v1.23.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const JC=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],eT=ee("zap",JC),fx=p.createContext(null);function tT(){const e=new Date,t=e.getHours()+e.getMinutes()/60;return t>=6.5&&t<21?"light":"dark"}function nT({children:e}){const[t,n]=p.useState(()=>{const s=localStorage.getItem("hifi-theme");return s==="light"||s==="dark"?s:tT()});p.useEffect(()=>{document.documentElement.classList.toggle("dark",t==="dark"),localStorage.setItem("hifi-theme",t)},[t]);const r=()=>n(s=>s==="dark"?"light":"dark");return l.jsx(fx.Provider,{value:{theme:t,toggleTheme:r},children:e})}function rT(){return p.useContext(fx)}const sT={nav:{mainNav:"Hauptnavigation",menu:"Menü",call:"Anrufen",openMenu:"Menü öffnen",closeMenu:"Menü schließen",close:"Schließen",adminPanel:"Zum Admin-Panel",vehicles:"Fahrzeuge",services:"Leistungen",gallery:"Galerie",contact:"Kontakt",whatsapp:"WhatsApp",shop:"Zum Shop",downloads:"Downloads"},themeToggle:{label:"Theme umschalten"},languageToggle:{label:"Sprache auswählen"},footer:{routePlan:"Route planen",contactHeading:"Kontakt",contactForm:"Kontaktformular",hoursHeading:"Öffnungszeiten",open:"Geöffnet",closed:"Geschlossen",days:{monFri:"Montag – Freitag",sat:"Samstag",sun:"Sonntag"},copyright:e=>`© ${e} HifiPlanet. Alle Angaben ohne Gewähr.`,imprint:"Impressum",privacy:"Datenschutz",terms:"AGB",downloads:"Downloads",cookieSettings:"Cookie-Einstellungen"},cookieConsent:{bannerText:"Wir verwenden nur technisch notwendige Cookies. Für Google Maps, YouTube-Videos und Statistik-Cookies benötigen wir zusätzlich deine Zustimmung, da dabei Daten an Google übertragen werden.",moreInfo:"Mehr dazu in unserer",privacyPolicy:"Datenschutzerklärung",settings:"Einstellungen",onlyNecessary:"Nur notwendige",acceptAll:"Alle akzeptieren",modalTitle:"Cookie-Einstellungen",modalIntro:"Lege fest, welche Kategorien du zulassen möchtest. Mehr dazu in unserer",necessaryTitle:"Notwendig",necessaryDesc:"Für den Betrieb der Website erforderlich (z. B. Login-Session, Theme- und Cookie-Einstellung). Kann nicht deaktiviert werden.",externalTitle:"Externe Medien",externalDesc:"Google Maps und YouTube-Videos. Beim Laden werden Daten (u. a. deine IP-Adresse) an Google übertragen.",analyticsTitle:"Statistik",analyticsDesc:"Google Analytics hilft uns zu verstehen, wie die Website genutzt wird. Dabei werden Daten an Google übertragen.",cancel:"Abbrechen",saveSelection:"Auswahl speichern"},maintenance:{title:"Wartungsarbeiten",defaultMessage:"Dieser Bereich wird gerade aktualisiert. Bitte schau in Kürze wieder vorbei.",login:"Anmelden"},lightbox:{close:"Schließen",previous:"Vorheriges Bild",next:"Nächstes Bild"},home:{metaTitle:"Car-Hifi Umbauten nach Maß",metaDescription:"HifiPlanet – dein Car-Hifi Spezialist in Amorbach. Marke und Modell wählen, passende Sound-Pakete entdecken und unverbindlich anfragen.",stickyCta:"Bereit für deinen Sound-Umbau?",selectVehicle:"Fahrzeug auswählen",getInTouch:"Kontakt aufnehmen",welcome:"Willkommen bei HifiPlanet",heroTitle:"Home of pure Sound",heroSubtitle:"Dein Car-Hifi Spezialist für individuelle Sound-Umbauten. Wähle dein Fahrzeug, entdecke passende Pakete und frag unverbindlich an – wir kümmern uns um den Rest.",stats:[{value:"20+",label:"Jahre Erfahrung"},{value:"Riesige",label:"3D-Druckfarm im eigenen Haus"},{value:"Eigene",label:"CNC- & Laserwerkstatt"},{value:"International",label:"anerkannter Car-Hifi-Spezialist"}],brandsHeading:"Marken, mit denen wir arbeiten",youtubeBadge:"HifiPlanet präsentiert",youtubeTitle:"Das Handwerk hinter deinem Sound",youtubeText:"Entdecke die Handwerkskunst hinter unserer Arbeit",youtubeCta:"Jetzt ansehen",heroImageAlt:"Ground Zero Subwoofer und Endstufen mit violetter Ambiente-Beleuchtung",craftImageAlt:"Individueller Subwoofer-Bau",adviceImageAlt:"Endstufen-Einbau mit Ambiente-Beleuchtung",moreImageAlt:"Hochwertige Endstufe und Subwoofer, Studioaufnahme",craftEyebrow:"Handwerk",craftTitle:"Präzisionsarbeit in jedem Detail",craftText:"Ob eigens gefertigte Subwoofer-Gehäuse, integrierte Beleuchtung oder unsichtbar verlegte Kabelwege – dank eigener CNC-, Laser- und 3D-Druck-Fertigung entstehen bei uns Lösungen, die es von der Stange nicht gibt.",adviceEyebrow:"Beratung",adviceTitle:"Von der ersten Idee bis zum letzten Schliff",adviceText:"Jedes Fahrzeug und jeder Anspruch ist anders. Deshalb beraten wir dich persönlich und unverbindlich – vom dezenten Upgrade bis zum kompromisslosen High-End-System.",insightsTitle:"Einblicke in unsere Umbauten",insightsText:"Vom unauffälligen Sound-Upgrade bis zum aufwendigen Komplettumbau – Handarbeit aus unserer Werkstatt in Amorbach.",galleryAlts:["Individueller Subwoofer-Bau mit Ground Zero Bässen","Endstufen-Einbau mit violetter Ambiente-Beleuchtung","Hochtöner- und Mitteltöner-Einbau von Focal Utopia","Sony Navigationssystem mit Apple CarPlay im Cockpit","Verbauter Hochtöner im Kofferraum","Individueller Subwoofer-Einbau mit LED-Beleuchtung im Kofferraum"],reviewsRating:"5,0 von 181 Kunden bewertet",reviewsRatingDynamic:(e,t)=>`${e.toFixed(1).replace(".",",")} von ${t} Kunden bewertet`,reviewsText:"Das sagen unsere Kunden über uns.",reviewsLink:"Alle Bewertungen auf Google ansehen →",testimonials:[{name:"Thomas K.",text:"Über YouTube auf dieses Klang-Juwel gestoßen. Beratung und Empfehlungen sind erstklassig – der Tesla-Vorführwagen hat meine Leidenschaft für guten Sound neu entfacht."},{name:"Andreas I.",text:"Sehr professionelle Beratung und Service. Obwohl ich von VAG zu Mercedes gewechselt bin, wurde alles reibungslos angepasst. Die 3-Wege-Lautsprecher und zwei Subwoofer liefern außergewöhnliche Leistung."},{name:"Thomas F.",text:"Kompletter Audi A4 B9 Umbau hat meine Erwartungen übertroffen. Von Anfang bis Ende professionell, mit tadelloser Verarbeitung und Klangqualität."},{name:"Drago G.",text:"Beeindruckt von der CNC-Arbeit, die auf YouTube gezeigt wird. Angefangen mit 3D-gedruckten Lautsprecherringen für meinen Ford Mustang – daraus wurde ein viel größeres Projekt."},{name:"Leonardo B.",text:"Toller Service und meisterhafte Handwerkskunst. Saubere Installation, Leidenschaft in jedem Detail erkennbar."},{name:"Marcel S.",text:"Unschlagbares Preis-Leistungs-Verhältnis. Das Team hat sich viel Zeit genommen, um genau die Lösung für mein Budget zu finden."},{name:"Julia W.",text:"Endlich ein Betrieb, der auch Wohnmobile ernst nimmt. Die Soundanlage in unserem Camper klingt jetzt wie im Wohnzimmer."},{name:"Kevin R.",text:"Dashcam und Alarmanlage in einem Termin sauber verbaut, keine sichtbaren Kabel. Absolute Empfehlung für alle, die Wert auf Verarbeitung legen."},{name:"Sabrina H.",text:"Mein Oldtimer hat jetzt modernen Sound, ohne dass es dem Original-Look geschadet hätte. Genau das habe ich gesucht."},{name:"Niklas P.",text:"Von der ersten Anfrage bis zum fertigen Umbau lief alles reibungslos. Ehrliche Beratung ohne Verkaufsdruck."}],moreTitle:"Mehr als nur Car-Hifi",moreText:"Neben individuellen Sound-Umbauten bieten wir CNC-Zerspanung, Lasertechnik, 3D-Druck und mehr – alles aus einer Hand in unserer eigenen Werkstatt.",moreCta:"Alle Leistungen entdecken",faqHeading:"Häufig gestellte Fragen"},vehicleSelect:{loading:"Marken werden geladen…",metaTitle:"Fahrzeug auswählen",metaDescription:"Wähle deine Fahrzeugmarke und dein Modell und entdecke passende Car-Hifi Sound-Pakete von HifiPlanet.",title:"Fahrzeug auswählen",intro:"Wähle zuerst deine Marke, dann dein Modell – wir zeigen dir direkt die passenden Sound-Pakete.",empty:"Es sind noch keine Marken hinterlegt."},brandPage:{metaTitleFallback:"Modell auswählen",metaDescription:e=>`Wähle dein ${e} Modell und entdecke passende Car-Hifi Sound-Pakete von HifiPlanet.`,loading:"Lädt…",breadcrumbVehicles:"Fahrzeuge",titleSuffix:"Modell wählen",empty:"Für diese Marke sind noch keine Modelle hinterlegt."},modelPage:{customRequest:"Individuell anfragen",customHint:"Nicht das Passende dabei? Wir stellen dir gerne ein Paket nach deinen Wünschen zusammen.",whatsappText:(e,t)=>`Hallo HifiPlanet, ich interessiere mich für einen Car-Hifi-Umbau für meinen ${e} ${t}.`,metaTitleFallback:"Sound-Pakete",metaTitle:(e,t)=>`${e} ${t} Sound-Pakete`,metaDescription:(e,t)=>`Car-Hifi Sound-Pakete für ${e} ${t} inkl. aktueller Preise – von HifiPlanet unverbindlich anfragen.`,loading:"Lädt…",breadcrumbVehicles:"Fahrzeuge",titleSuffix:"Sound-Pakete",empty:"Für dieses Modell sind noch keine Pakete hinterlegt.",totalPrice:"ab ca.",productLoading:"Produkt wird geladen…",requestContact:"Kontakt anfragen",badges:{recommended:"Empfohlen",popular:"Am beliebtesten",tip:"Tipp",coming_soon:"Coming soon"},videoLink:"Zum Video",moreBullets:e=>e===1?"+ 1 weitere Leistung":`+ ${e} weitere Leistungen`,showMore:"Mehr anzeigen",lessBullets:"Weniger anzeigen",wheelHint:"Mit dem Mausrad blättern"},leistungen:{metaTitle:"Leistungen",metaDescription:"Car-Hifi, Wohnmobil & Caravan, Oldtimer, CNC-Zerspanung, Lasertechnik, 3D-Druck, Alarmanlagen und Dash Cams – alles aus einer Hand bei HifiPlanet in Amorbach.",title:"Unsere Leistungen",intro:"Von individuellen Sound-Umbauten bis zur eigenen CNC- und 3D-Druck-Fertigung – alles aus einer Hand in unserer Werkstatt in Amorbach.",notListedTitle:"Dein Projekt ist nicht dabei?",notListedText:"Sprich uns einfach an – wir finden gemeinsam die passende Lösung.",contact:"Kontakt aufnehmen"},contactPage:{sendAnother:"Weitere Anfrage senden",vehicleBoxTitle:"Dein Fahrzeug:",privacyPre:"Mit dem Absenden stimmst du zu, dass wir deine Angaben zur Bearbeitung der Anfrage verwenden. Mehr dazu in der ",privacyLink:"Datenschutzerklärung",privacyPost:".",mapIframeTitle:"Standort von HifiPlanet in Amorbach auf Google Maps",whatsappText:(e,t,n)=>`Hallo HifiPlanet, ich interessiere mich für das Paket "${n}" für meinen ${e} ${t}.`,metaTitle:"Kontakt",metaDescription:"Kontaktiere HifiPlanet in Amorbach für dein individuelles Car-Hifi Projekt – wir beraten dich gerne unverbindlich.",title:"Kontakt aufnehmen",heroEyebrow:"Kontakt",heroTitlePre:"Sprich",heroTitleAccent:"mit",heroTitlePost:"uns.",heroSubtitle:"Ob Anlage, Einbau oder Klang-Tuning für dein Fahrzeug — schreib uns, wir melden uns schnellstmöglich zurück.",packageBoxTitle:"Deine Anfrage bezieht sich auf",formTitle:"Anfrage senden",sentTitle:"Anfrage gesendet ✓",sentText:"Danke! Wir melden uns innerhalb eines Werktags bei dir.",contextIntro:"Deine Anfrage bezieht sich auf:",contextBrand:"Marke",contextModel:"Modell",contextPackage:"Paket",contextProduct:"Produkt",packagePrice:"Paketpreis",upgrades:"Upgrades",optionalUpgrades:"Optionale Upgrades",totalWithUpgrades:"Gesamt inkl. Upgrades",nameLabel:"Name *",namePlaceholder:"Max Mustermann",emailLabel:"E-Mail *",emailPlaceholder:"max@mail.de",phoneLabel:"Telefon",phonePlaceholder:"Optional",vinLabel:"Fahrgestellnummer (FIN)",vinPlaceholder:"Optional – hilft bei der Einschätzung",messageLabel:"Nachricht",messagePlaceholder:"Erzähl uns von deinem Projekt – Fahrzeug, Wunschklang, Budget …",requiredHint:"* Pflichtfelder",sending:"Wird gesendet…",submit:"Anfrage senden",cardTitle:"HiFi Planet Amorbach",address:"Adresse",phone:"Telefon",email:"E-Mail",hours:"Öffnungszeiten",hoursWeek:"Mo–Fr: 9:00–18:00 Uhr",hoursSat:"Sa: 10:00–13:00 Uhr",hoursWeekDays:"Mo–Fr",hoursWeekTime:"9:00 – 18:00 Uhr",hoursSatDay:"Sa",hoursSatTime:"10:00 – 13:00 Uhr",directionsTitle:"Anfahrt",mapEmbedName:"Die Google-Maps-Karte",mapOpenChip:"In Maps öffnen",routePlan:"Route planen",featurePremiumTitle:"Premium Klang",featurePremiumSub:"Höchste Qualität",featureGermanyTitle:"Made in Germany",featureGermanySub:"Präzise Handarbeit",featureIndividualTitle:"Individuell",featureIndividualSub:"Maßgeschneiderte Lösungen",featureExpertsTitle:"Experten Team",featureExpertsSub:"Leidenschaft & Know-how"},galleryOverview:{metaTitle:"Bildergalerie",metaDescription:"Einblicke in unsere Car-Hifi Umbauten – nach Marke sortiert. Wähle eine Marke und entdecke die Projekte.",title:"Bildergalerie",intro:"Wähle eine Marke und entdecke unsere Umbauten im Detail.",loading:"Lädt…",empty:"Es sind noch keine Galerie-Marken hinterlegt."},galleryBrandPage:{metaTitleFallback:"Bildergalerie",metaTitle:e=>`${e} Umbauten`,metaDescription:e=>`Einblicke in unsere ${e} Car-Hifi Umbauten.`,loading:"Lädt…",breadcrumbGallery:"Galerie",titleSuffix:"Projekt wählen",empty:"Für diese Marke sind noch keine Projekte hinterlegt."},galleryProjectPage:{ctaTitle:"So etwas für dein Auto?",ctaText:"Erzähl uns von deinem Fahrzeug – wir planen einen ähnlichen Umbau für dich.",ctaButton:"Ähnlichen Umbau anfragen",ctaTopic:e=>`Mich interessiert ein ähnlicher Umbau wie "${e}" aus eurer Galerie.`,metaTitleFallback:"Bildergalerie",metaDescription:e=>`Fotos unseres ${e} Umbaus.`,loading:"Lädt…",breadcrumbGallery:"Galerie",empty:"Für dieses Projekt sind noch keine Fotos hinterlegt.",enlargeImage:"Bild vergrößern"},downloadsPage:{metaTitle:"Downloads",metaDescription:"Dateien und Songs von HifiPlanet zum Anhören und Herunterladen.",title:"Downloads",intro:"Hier stellen wir dir Dateien und Songs bereit – direkt anhören oder herunterladen.",loading:"Lädt…",empty:"Aktuell stehen keine Downloads bereit.",download:"Herunterladen",lockedTitle:"Geschützter Bereich",lockedText:"Bitte gib das Passwort ein, das du von uns bekommen hast.",passwordLabel:"Passwort",unlock:"Freischalten",unlocking:"Wird geprüft…",wrongPassword:"Das Passwort stimmt leider nicht."},errors:{generic:"Da ist etwas schiefgelaufen. Bitte versuche es noch einmal.",network:"Keine Verbindung zum Server. Bitte prüfe deine Internetverbindung.",notFound:"Diese Seite gibt es nicht (mehr).",rateLimited:"Zu viele Anfragen in kurzer Zeit. Bitte versuche es später noch einmal oder ruf uns an.",invalidInput:"Bitte gib deinen Namen und eine gültige E-Mail-Adresse an.",server:"Auf dem Server ist ein Fehler aufgetreten. Bitte versuche es später noch einmal.",maintenance:"Dieser Bereich wird gerade überarbeitet. Bitte schau später wieder vorbei."},notFound:{metaTitle:"Seite nicht gefunden",title:"Diese Seite haben wir nicht gefunden",text:"Vielleicht ist der Link veraltet oder hat einen Tippfehler. Hier geht es direkt weiter:",toVehicles:"Fahrzeug wählen",toContact:"Kontakt aufnehmen",toHome:"Zur Startseite"}},iT={nav:{mainNav:"Main navigation",menu:"Menu",call:"Call",openMenu:"Open menu",closeMenu:"Close menu",close:"Close",adminPanel:"Go to admin panel",vehicles:"Vehicles",services:"Services",gallery:"Gallery",contact:"Contact",whatsapp:"WhatsApp",shop:"Visit shop",downloads:"Downloads"},themeToggle:{label:"Toggle theme"},languageToggle:{label:"Select language"},footer:{routePlan:"Get directions",contactHeading:"Contact",contactForm:"Contact form",hoursHeading:"Opening hours",open:"Open",closed:"Closed",days:{monFri:"Monday – Friday",sat:"Saturday",sun:"Sunday"},copyright:e=>`© ${e} HifiPlanet. All information without guarantee.`,imprint:"Legal notice",privacy:"Privacy",terms:"Terms",downloads:"Downloads",cookieSettings:"Cookie settings"},cookieConsent:{bannerText:"We only use technically necessary cookies. For Google Maps, YouTube videos and analytics cookies we need your additional consent, since data is transferred to Google in that case.",moreInfo:"More details in our",privacyPolicy:"privacy policy",settings:"Settings",onlyNecessary:"Necessary only",acceptAll:"Accept all",modalTitle:"Cookie settings",modalIntro:"Choose which categories you want to allow. More details in our",necessaryTitle:"Necessary",necessaryDesc:"Required to operate the website (e.g. login session, theme and cookie preference). Cannot be disabled.",externalTitle:"External media",externalDesc:"Google Maps and YouTube videos. Loading them transfers data (including your IP address) to Google.",analyticsTitle:"Analytics",analyticsDesc:"Google Analytics helps us understand how the website is used. This transfers data to Google.",cancel:"Cancel",saveSelection:"Save selection"},maintenance:{title:"Under maintenance",defaultMessage:"This area is currently being updated. Please check back shortly.",login:"Log in"},lightbox:{close:"Close",previous:"Previous image",next:"Next image"},home:{metaTitle:"Custom Car-Hifi Installations",metaDescription:"HifiPlanet – your car-hifi specialist in Amorbach, Germany. Choose your make and model, discover matching sound packages and get in touch, no obligation.",stickyCta:"Ready for your sound upgrade?",selectVehicle:"Select vehicle",getInTouch:"Get in touch",welcome:"Welcome to HifiPlanet",heroTitle:"Home of pure Sound",heroSubtitle:"Your car-hifi specialist for custom sound installations. Choose your vehicle, discover the right package and get in touch, no obligation – we take care of the rest.",stats:[{value:"20+",label:"years of experience"},{value:"Huge",label:"in-house 3D print farm"},{value:"In-house",label:"CNC & laser workshop"},{value:"International",label:"recognized car-hifi specialist"}],brandsHeading:"Brands we work with",youtubeBadge:"HifiPlanet presents",youtubeTitle:"The craft behind your sound",youtubeText:"Discover the artistry behind our work",youtubeCta:"Watch now",heroImageAlt:"Ground Zero subwoofer and amplifiers with purple ambient lighting",craftImageAlt:"Custom subwoofer build",adviceImageAlt:"Amplifier installation with ambient lighting",moreImageAlt:"High-end amplifier and subwoofer, studio shot",craftEyebrow:"Craftsmanship",craftTitle:"Precision work in every detail",craftText:"Whether custom-built subwoofer enclosures, integrated lighting or invisibly routed cabling – our own CNC, laser and 3D-printing production means we can build solutions you simply can't buy off the shelf.",adviceEyebrow:"Consultation",adviceTitle:"From the first idea to the final touch",adviceText:"Every vehicle and every requirement is different. That's why we advise you personally and without obligation – from a subtle upgrade to an uncompromising high-end system.",insightsTitle:"A look at our installations",insightsText:"From subtle sound upgrades to elaborate full installations – handcrafted in our workshop in Amorbach.",galleryAlts:["Custom subwoofer build with Ground Zero bass drivers","Amplifier installation with purple ambient lighting","Tweeter and midrange installation by Focal Utopia","Sony navigation system with Apple CarPlay in the cockpit","Installed tweeter in the trunk","Custom subwoofer installation with LED lighting in the trunk"],reviewsRating:"Rated 5.0 by 181 customers",reviewsRatingDynamic:(e,t)=>`Rated ${e.toFixed(1)} by ${t} customers`,reviewsText:"Here's what our customers say about us.",reviewsLink:"See all reviews on Google →",testimonials:[{name:"Thomas K.",text:"Found this gem through YouTube. Advice and recommendations are top-notch – the Tesla demo car reignited my passion for great sound."},{name:"Andreas I.",text:"Very professional advice and service. Even though I switched from VAG to Mercedes, everything was adapted smoothly. The 3-way speakers and two subwoofers deliver outstanding performance."},{name:"Thomas F.",text:"The complete Audi A4 B9 build exceeded my expectations. Professional from start to finish, with flawless workmanship and sound quality."},{name:"Drago G.",text:"Impressed by the CNC work shown on YouTube. Started with 3D-printed speaker rings for my Ford Mustang – it turned into a much bigger project."},{name:"Leonardo B.",text:"Great service and masterful craftsmanship. Clean installation, passion visible in every detail."},{name:"Marcel S.",text:"Unbeatable value for money. The team took a lot of time to find the exact solution for my budget."},{name:"Julia W.",text:"Finally a shop that takes motorhomes seriously too. The sound system in our camper now sounds like a living room."},{name:"Kevin R.",text:"Dash cam and alarm system installed cleanly in a single appointment, no visible cables. Highly recommended for anyone who values quality workmanship."},{name:"Sabrina H.",text:"My classic car now has modern sound without compromising the original look. Exactly what I was looking for."},{name:"Niklas P.",text:"From the first inquiry to the finished build, everything went smoothly. Honest advice with no sales pressure."}],moreTitle:"More than just car-hifi",moreText:"Besides custom sound installations, we also offer CNC machining, laser technology, 3D printing and more – all from a single source in our own workshop.",moreCta:"Discover all our services",faqHeading:"Frequently asked questions"},vehicleSelect:{loading:"Loading brands…",metaTitle:"Select your vehicle",metaDescription:"Choose your vehicle make and model and discover matching car-hifi sound packages from HifiPlanet.",title:"Select your vehicle",intro:"Choose your make first, then your model – we'll show you the matching sound packages right away.",empty:"No brands have been added yet."},brandPage:{metaTitleFallback:"Select a model",metaDescription:e=>`Choose your ${e} model and discover matching car-hifi sound packages from HifiPlanet.`,loading:"Loading…",breadcrumbVehicles:"Vehicles",titleSuffix:"Select a model",empty:"No models have been added for this brand yet."},modelPage:{customRequest:"Request a custom setup",customHint:"Nothing quite right? We will happily put together a package to suit you.",whatsappText:(e,t)=>`Hello HifiPlanet, I am interested in a car audio upgrade for my ${e} ${t}.`,metaTitleFallback:"Sound packages",metaTitle:(e,t)=>`${e} ${t} sound packages`,metaDescription:(e,t)=>`Car-hifi sound packages for the ${e} ${t} including current prices – get in touch with HifiPlanet, no obligation.`,loading:"Loading…",breadcrumbVehicles:"Vehicles",titleSuffix:"Sound packages",empty:"No packages have been added for this model yet.",totalPrice:"from approx.",productLoading:"Loading product…",requestContact:"Request contact",badges:{recommended:"Recommended",popular:"Most popular",tip:"Tip",coming_soon:"Coming soon"},videoLink:"Watch video",moreBullets:e=>e===1?"+ 1 more feature":`+ ${e} more features`,showMore:"Show more",lessBullets:"Show less",wheelHint:"Scroll to browse"},leistungen:{metaTitle:"Services",metaDescription:"Car-hifi, motorhomes & caravans, classic cars, CNC machining, laser technology, 3D printing, alarm systems and dash cams – all from a single source at HifiPlanet in Amorbach.",title:"Our services",intro:"From custom sound installations to our own CNC and 3D-printing production – all from a single source in our workshop in Amorbach.",notListedTitle:"Don't see your project?",notListedText:"Just get in touch – we'll find the right solution together.",contact:"Get in touch"},contactPage:{sendAnother:"Send another request",vehicleBoxTitle:"Your vehicle:",privacyPre:"By sending this form you agree that we use your details to handle your request. Learn more in our ",privacyLink:"privacy policy",privacyPost:".",mapIframeTitle:"HifiPlanet location in Amorbach on Google Maps",whatsappText:(e,t,n)=>`Hello HifiPlanet, I am interested in the "${n}" package for my ${e} ${t}.`,metaTitle:"Contact",metaDescription:"Get in touch with HifiPlanet in Amorbach for your custom car-hifi project – we're happy to advise you, no obligation.",title:"Get in touch",heroEyebrow:"Contact",heroTitlePre:"Talk",heroTitleAccent:"to",heroTitlePost:"us.",heroSubtitle:"Whether it's a system, installation, or sound tuning for your car — write to us, we'll get back to you as soon as possible.",packageBoxTitle:"Your inquiry relates to",formTitle:"Send inquiry",sentTitle:"Inquiry sent ✓",sentText:"Thanks! We'll get back to you within one business day.",contextIntro:"Your inquiry relates to:",contextBrand:"Brand",contextModel:"Model",contextPackage:"Package",contextProduct:"Product",packagePrice:"Package price",upgrades:"Upgrades",optionalUpgrades:"Optional upgrades",totalWithUpgrades:"Total incl. upgrades",nameLabel:"Name *",namePlaceholder:"Max Mustermann",emailLabel:"Email *",emailPlaceholder:"max@mail.de",phoneLabel:"Phone",phonePlaceholder:"Optional",vinLabel:"Vehicle identification number (VIN)",vinPlaceholder:"Optional – helps us assess your vehicle",messageLabel:"Message",messagePlaceholder:"Tell us about your project – vehicle, desired sound, budget …",requiredHint:"* Required fields",sending:"Sending…",submit:"Send inquiry",cardTitle:"HiFi Planet Amorbach",address:"Address",phone:"Phone",email:"Email",hours:"Opening hours",hoursWeek:"Mon–Fri: 9:00 AM–6:00 PM",hoursSat:"Sat: 10:00 AM–1:00 PM",hoursWeekDays:"Mon–Fri",hoursWeekTime:"9:00 AM – 6:00 PM",hoursSatDay:"Sat",hoursSatTime:"10:00 AM – 1:00 PM",directionsTitle:"Directions",mapEmbedName:"The Google Maps map",mapOpenChip:"Open in Maps",routePlan:"Get directions",featurePremiumTitle:"Premium Sound",featurePremiumSub:"Highest quality",featureGermanyTitle:"Made in Germany",featureGermanySub:"Precision craftsmanship",featureIndividualTitle:"Custom-built",featureIndividualSub:"Tailored solutions",featureExpertsTitle:"Expert Team",featureExpertsSub:"Passion & know-how"},galleryOverview:{metaTitle:"Photo gallery",metaDescription:"A look at our car-hifi installations – sorted by brand. Choose a brand and explore the projects.",title:"Photo gallery",intro:"Choose a brand and explore our installations in detail.",loading:"Loading…",empty:"No gallery brands have been added yet."},galleryBrandPage:{metaTitleFallback:"Photo gallery",metaTitle:e=>`${e} installations`,metaDescription:e=>`A look at our ${e} car-hifi installations.`,loading:"Loading…",breadcrumbGallery:"Gallery",titleSuffix:"Select a project",empty:"No projects have been added for this brand yet."},galleryProjectPage:{ctaTitle:"Want something like this for your car?",ctaText:"Tell us about your vehicle and we will plan a similar build for you.",ctaButton:"Request a similar build",ctaTopic:e=>`I am interested in a build similar to "${e}" from your gallery.`,metaTitleFallback:"Photo gallery",metaDescription:e=>`Photos of our ${e} installation.`,loading:"Loading…",breadcrumbGallery:"Gallery",empty:"No photos have been added for this project yet.",enlargeImage:"Enlarge image"},downloadsPage:{metaTitle:"Downloads",metaDescription:"Files and songs from HifiPlanet to listen to and download.",title:"Downloads",intro:"Here you will find files and songs we provide for you – listen right here or download them.",loading:"Loading…",empty:"There are no downloads available right now.",download:"Download",lockedTitle:"Protected area",lockedText:"Please enter the password you received from us.",passwordLabel:"Password",unlock:"Unlock",unlocking:"Checking…",wrongPassword:"Sorry, that password is not correct."},errors:{generic:"Something went wrong. Please try again.",network:"No connection to the server. Please check your internet connection.",notFound:"This page does not exist (anymore).",rateLimited:"Too many requests in a short time. Please try again later or give us a call.",invalidInput:"Please enter your name and a valid email address.",server:"A server error occurred. Please try again later.",maintenance:"This section is being updated. Please check back later."},notFound:{metaTitle:"Page not found",title:"We could not find this page",text:"The link may be outdated or contain a typo. Continue here:",toVehicles:"Choose your vehicle",toContact:"Get in touch",toHome:"Back to the homepage"}},Qi={de:sT,en:iT};function oT(){const e=localStorage.getItem("hifi-lang");return e==="de"||e==="en"?e:(navigator.language||"de").toLowerCase().startsWith("de")?"de":"en"}function Bu(e,t){return t.split(".").reduce((n,r)=>n==null?void 0:n[r],e)}const hx=p.createContext({language:"de",setLanguage:()=>{},toggleLanguage:()=>{},t:e=>{const t=Bu(Qi.de,e);return t!==void 0?t:e}});function Sm({children:e}){const[t,n]=p.useState(oT);p.useEffect(()=>{document.documentElement.setAttribute("lang",t),localStorage.setItem("hifi-lang",t)},[t]);const r=()=>n(i=>i==="de"?"en":"de"),s=i=>{const o=Qi[t]||Qi.de,a=Bu(o,i);if(a!==void 0)return a;const u=Bu(Qi.de,i);return u!==void 0?u:i};return l.jsx(hx.Provider,{value:{language:t,setLanguage:n,toggleLanguage:r,t:s},children:e})}function rt(){return p.useContext(hx)}function mx({overHero:e=!1,forceDark:t=!1}){const{theme:n,toggleTheme:r}=rT(),{t:s}=rt();return l.jsx("button",{onClick:r,"aria-label":s("themeToggle.label"),className:`rounded-full p-2 transition ${e?"text-white hover:bg-white/10":t?"text-neutral-300 hover:bg-neutral-800":"text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:n==="dark"?l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"h-5 w-5",children:l.jsx("path",{d:"M12 3a1 1 0 011 1v1a1 1 0 11-2 0V4a1 1 0 011-1zm0 15a5 5 0 100-10 5 5 0 000 10zm9-6a1 1 0 010 2h-1a1 1 0 110-2h1zM4 12a1 1 0 010 2H3a1 1 0 110-2h1zm14.36-7.36a1 1 0 011.42 1.42l-.71.7a1 1 0 11-1.41-1.4l.7-.72zM5.64 18.36a1 1 0 011.41 1.41l-.7.71a1 1 0 11-1.42-1.41l.71-.71zm12.72 0l.71.7a1 1 0 11-1.41 1.42l-.71-.71a1 1 0 011.41-1.41zM6.34 5.64l-.7-.7A1 1 0 117.05 3.5l.7.71A1 1 0 016.34 5.64zM12 6a1 1 0 011-1v0a1 1 0 01-1 1zm0 12a1 1 0 011 1v1a1 1 0 11-2 0v-1a1 1 0 011-1z"})}):l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"h-5 w-5",children:l.jsx("path",{fillRule:"evenodd",d:"M9.53 2.25a.75.75 0 01.19.82 8.25 8.25 0 0011.03 11.03.75.75 0 011.01.99A10.5 10.5 0 1112.9 2.1a.75.75 0 011.63-.85z",clipRule:"evenodd"})})})}const px=p.createContext(null);function aT({children:e}){const[t,n]=p.useState(null),[r,s]=p.useState(!0);p.useEffect(()=>{ce.get("/auth/me").then(d=>n(d.authenticated===!1?null:d)).catch(()=>n(null)).finally(()=>s(!1))},[]);const i=async(d,f)=>{const h=await ce.post("/auth/login",{username:d,password:f});return h.requires_2fa?{requires2fa:!0}:(n(h),{requires2fa:!1})},o=async d=>{const f=await ce.post("/auth/verify-2fa",{code:d});n(f)},a=async()=>{await ce.post("/auth/logout",{}),n(null)},u=async()=>{const d=await ce.get("/auth/me");n(d.authenticated===!1?null:d)},c=d=>{var f;return!!t&&(t.is_super_admin||((f=t.permissions)==null?void 0:f.includes(d)))};return l.jsx(px.Provider,{value:{user:t,loading:r,login:i,verifyTwoFactor:o,logout:a,refreshUser:u,hasPermission:c},children:e})}function qr(){return p.useContext(px)}const bd=p.createContext({phone:"09373 20 62 390",whatsapp:null,contact_email:"info@hifi-planet-amorbach.de",address_street:"Boxbrunner Str. 20a",address_zip:"63916",address_city:"Amorbach",logo_path:null,logo_dark_path:null,business_hours:null,hero_image_path:null,ga_measurement_id:null,gallery_card_text_x:0,gallery_card_text_y:100,site_font:null,page_loader_enabled:1,package_card_width:210,package_card_height:480,vehicle_tile_width:240,vehicle_tile_height:180,hidden_areas:[]}),lT=bd.Provider;function Lt(){return p.useContext(bd)}function da(){const{hidden_areas:e}=p.useContext(bd);return t=>(e||[]).includes(t)}const Hu="/assets/logo-dark-R-ckaBhx.png",gx=e=>(e||"").replace(/[^\d+]/g,""),Sd=e=>`tel:${gx(e)}`,Pd=(e,t="")=>`https://wa.me/${gx(e).replace(/^0/,"49").replace("+","")}${t?`?text=${encodeURIComponent(t)}`:""}`;function Sn(e,t={}){typeof window>"u"||typeof window.gtag!="function"||window.gtag("event",e,t)}const uT="https://www.audio4cars.de/",Pm=70,cT=500;function dT({className:e}){return l.jsxs("svg",{viewBox:"0 0 3 2",className:e,"aria-hidden":"true",children:[l.jsx("rect",{width:"3",height:"0.667",y:"0",fill:"#000"}),l.jsx("rect",{width:"3",height:"0.667",y:"0.667",fill:"#D00"}),l.jsx("rect",{width:"3",height:"0.666",y:"1.334",fill:"#FFCE00"})]})}function fT({className:e}){return l.jsxs("svg",{viewBox:"0 0 60 30",className:e,"aria-hidden":"true",children:[l.jsx("clipPath",{id:"fgb-t",children:l.jsx("path",{d:"M30,15 h30 v15 z v15 h-30 z h-30 v-15 z v-15 h30 z"})}),l.jsx("path",{d:"M0,0 v30 h60 v-30 z",fill:"#00247d"}),l.jsx("path",{d:"M0,0 L60,30 M60,0 L0,30",stroke:"#fff",strokeWidth:"6"}),l.jsx("path",{d:"M0,0 L60,30 M60,0 L0,30",clipPath:"url(#fgb-t)",stroke:"#cf142b",strokeWidth:"4"}),l.jsx("path",{d:"M30,0 v30 M0,15 h60",stroke:"#fff",strokeWidth:"10"}),l.jsx("path",{d:"M30,0 v30 M0,15 h60",stroke:"#cf142b",strokeWidth:"6"})]})}const al=[{code:"de",label:"Deutsch",Flag:dT},{code:"en",label:"English",Flag:fT}];function hT({overHero:e=!1}){const{language:t,setLanguage:n,t:r}=rt(),[s,i]=p.useState(!1),o=p.useRef(null),a=al.find(u=>u.code===t)||al[0];return p.useEffect(()=>{if(!s)return;const u=d=>{o.current&&!o.current.contains(d.target)&&i(!1)},c=d=>{d.key==="Escape"&&i(!1)};return document.addEventListener("mousedown",u),document.addEventListener("keydown",c),()=>{document.removeEventListener("mousedown",u),document.removeEventListener("keydown",c)}},[s]),l.jsxs("div",{className:"relative",ref:o,children:[l.jsxs("button",{type:"button",onClick:()=>i(u=>!u),"aria-haspopup":"listbox","aria-expanded":s,"aria-label":r("languageToggle.label"),className:`flex items-center gap-1 rounded-full p-1.5 transition ${e?"hover:bg-white/10":"hover:bg-neutral-800"}`,children:[l.jsx("span",{className:`block h-4 w-6 shrink-0 overflow-hidden rounded-[3px] ring-1 ${e?"ring-white/50":"ring-neutral-600"}`,children:l.jsx(a.Flag,{className:"h-full w-full"})}),l.jsx("svg",{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",className:`h-3 w-3 transition-transform ${e?"text-white/70":"text-neutral-400"} ${s?"rotate-180":""}`,children:l.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M5.23 7.21a.75.75 0 011.06.02L10 11.168l3.71-3.938a.75.75 0 111.08 1.04l-4.25 4.5a.75.75 0 01-1.08 0l-4.25-4.5a.75.75 0 01.02-1.06z"})})]}),s&&l.jsx("div",{role:"listbox",className:"absolute right-0 z-50 mt-2 min-w-[9rem] overflow-hidden rounded-lg border border-neutral-700 bg-neutral-900 py-1 shadow-lg",children:al.map(u=>l.jsxs("button",{type:"button",role:"option","aria-selected":u.code===t,onClick:()=>{n(u.code),i(!1)},className:`flex w-full items-center gap-2 px-3 py-2 text-left text-sm transition hover:bg-neutral-800 ${u.code===t?"font-semibold text-brand-400":"text-neutral-200"}`,children:[l.jsx("span",{className:"block h-4 w-6 shrink-0 overflow-hidden rounded-[3px] ring-1 ring-neutral-600",children:l.jsx(u.Flag,{className:"h-full w-full"})}),u.label]},u.code))})]})}function mT(){const[e,t]=p.useState(!1),[n,r]=p.useState(!1),[s,i]=p.useState(!1),{user:o}=qr(),{phone:a,whatsapp:u,logo_dark_path:c,has_downloads:d}=Lt(),f=da(),{t:h}=rt(),y=!f("page.vehicles"),x=!f("page.services"),w=!f("page.gallery"),b=d&&!f("page.downloads"),m=3+[y,x,w,b,a,u].filter(Boolean).length,v=nt().pathname==="/",[k,S]=p.useState(!v);p.useEffect(()=>{if(!v){S(!0);return}const $=()=>S(window.scrollY>24);return $(),window.addEventListener("scroll",$,{passive:!0}),()=>window.removeEventListener("scroll",$)},[v]);const C=v&&!k,j=p.useRef(null),P=p.useRef(null);p.useEffect(()=>{if(!e)return;const $=document.body.style.overflow;document.body.style.overflow="hidden";const se=setTimeout(()=>{var X,N;return(N=(X=j.current)==null?void 0:X.querySelector("button, a"))==null?void 0:N.focus()},50),G=X=>{if(X.key==="Escape"){t(!1);return}if(X.key!=="Tab"||!j.current)return;const N=[...j.current.querySelectorAll("a[href], button")];if(!N.length)return;const L=N[0],F=N[N.length-1];X.shiftKey&&document.activeElement===L?(X.preventDefault(),F.focus()):!X.shiftKey&&document.activeElement===F&&(X.preventDefault(),L.focus())};return document.addEventListener("keydown",G),()=>{var X;clearTimeout(se),document.body.style.overflow=$,document.removeEventListener("keydown",G),(X=P.current)==null||X.focus({preventScroll:!0})}},[e]),p.useEffect(()=>{if(e){r(!0);let G;const X=requestAnimationFrame(()=>{G=requestAnimationFrame(()=>i(!0))});return()=>{cancelAnimationFrame(X),G&&cancelAnimationFrame(G)}}i(!1);const $=cT+(m-1)*Pm,se=setTimeout(()=>r(!1),$);return()=>clearTimeout(se)},[e,m]);const M=()=>`transition-all duration-500 ease-out ${s?"opacity-100":"opacity-0"}`,E=$=>({transitionDelay:`${(s?$:m-1-$)*Pm}ms`,transform:s?"translateY(0)":"translateY(-140px)"}),O=o&&l.jsx(W,{to:"/admin","aria-label":h("nav.adminPanel"),title:h("nav.adminPanel"),className:`rounded-full p-2 transition ${C?"text-white hover:bg-white/10":"text-neutral-300 hover:bg-neutral-800"}`,children:l.jsx(CC,{className:"h-5 w-5"})});let K=0;const H=()=>E(K++);return l.jsxs("header",{className:`sticky top-0 z-30 border-b transition-colors duration-300 ${C?"border-transparent bg-transparent":"border-neutral-800 bg-neutral-950/90 backdrop-blur"}`,children:[l.jsxs("div",{className:"mx-auto grid max-w-6xl grid-cols-[1fr_auto_1fr] items-center gap-3 px-4 py-3 sm:px-6",children:[l.jsx("div",{className:"flex items-center justify-self-start",children:l.jsx("button",{ref:P,onClick:()=>t(!0),"aria-label":h("nav.openMenu"),"aria-expanded":e,"aria-haspopup":"dialog",className:`rounded-md p-2 transition ${C?"text-white hover:bg-white/10":"text-neutral-300 hover:bg-neutral-800"}`,children:l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-6 w-6",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 6h16M4 12h16M4 18h16"})})})}),l.jsx(W,{to:"/",className:"flex items-center justify-self-center rounded-lg px-2 py-1",children:l.jsx("img",{src:c||Hu,alt:"HifiPlanet",className:"h-14 w-auto sm:h-16"})}),l.jsxs("div",{className:"flex items-center justify-self-end gap-1",children:[O,!e&&l.jsx(hT,{overHero:C}),l.jsx(mx,{overHero:C,forceDark:!0})]})]}),n&&Vc.createPortal(l.jsx("div",{ref:j,role:"dialog","aria-modal":"true","aria-label":h("nav.menu"),className:"fixed inset-0 z-[100] overflow-y-auto text-left backdrop-blur-xl",style:{background:"linear-gradient(135deg, rgba(241,245,249,0.55) 0%, rgba(227,240,207,0.55) 50%, rgba(248,250,252,0.55) 100%)"},children:l.jsxs("div",{className:"relative mx-auto flex min-h-full max-w-6xl flex-col items-start justify-center gap-5 py-24 pl-6 pr-8 sm:pl-8",children:[l.jsxs("button",{onClick:()=>t(!1),"aria-label":h("nav.closeMenu"),className:"absolute left-6 top-8 flex items-center gap-2 text-neutral-600 hover:text-brand-600 sm:left-8 sm:top-[65px]",children:[l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-6 w-6",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 6l12 12M18 6 6 18"})}),l.jsx("span",{className:"text-xs font-semibold uppercase tracking-wide",children:h("nav.close")})]}),y&&l.jsx(W,{to:"/fahrzeuge",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${M()}`,style:H(),children:h("nav.vehicles")}),x&&l.jsx(W,{to:"/leistungen",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${M()}`,style:H(),children:h("nav.services")}),w&&l.jsx(W,{to:"/galerie",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${M()}`,style:H(),children:h("nav.gallery")}),l.jsx(W,{to:"/kontakt",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${M()}`,style:H(),children:h("nav.contact")}),b&&l.jsx(W,{to:"/downloads",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${M()}`,style:H(),children:h("nav.downloads")}),l.jsx("div",{className:`h-px w-16 bg-brand-500/60 ${M()}`,style:H()}),a&&l.jsxs("a",{href:Sd(a),onClick:()=>Sn("contact_call"),className:`flex items-center gap-2 text-sm font-semibold uppercase tracking-wide text-neutral-600 hover:text-brand-600 ${M()}`,style:H(),children:[l.jsx(Or,{className:"h-4 w-4"}),a]}),u&&l.jsxs("a",{href:Pd(u),onClick:()=>Sn("contact_whatsapp"),target:"_blank",rel:"noopener noreferrer",className:`flex items-center gap-2 text-sm font-semibold uppercase tracking-wide text-neutral-600 hover:text-brand-600 ${M()}`,style:H(),children:[l.jsx(dx,{className:"h-4 w-4"}),h("nav.whatsapp")]}),l.jsxs("a",{href:uT,target:"_blank",rel:"noopener noreferrer",className:`flex items-center gap-2 text-sm font-semibold uppercase tracking-wide text-neutral-600 hover:text-brand-600 ${M()}`,style:H(),children:[l.jsx(GC,{className:"h-4 w-4"}),h("nav.shop")]})]})}),document.body)]})}const jm="hifiplanet-cookie-consent",yx={necessary:!0,external:!1,analytics:!1},xx=p.createContext({consent:yx,decided:!1,settingsOpen:!1,acceptAll:()=>{},rejectNonEssential:()=>{},saveCustom:()=>{},openSettings:()=>{},closeSettings:()=>{}});function pT({children:e}){const[t,n]=p.useState(yx),[r,s]=p.useState(!1),[i,o]=p.useState(!1);p.useEffect(()=>{try{const y=localStorage.getItem(jm);if(y){const x=JSON.parse(y);n({necessary:!0,external:!!x.external,analytics:!!x.analytics}),s(!0)}}catch{}},[]);const a=p.useCallback(y=>{n(y),s(!0),o(!1),localStorage.setItem(jm,JSON.stringify({...y,decidedAt:new Date().toISOString()}))},[]),u=p.useCallback(()=>a({necessary:!0,external:!0,analytics:!0}),[a]),c=p.useCallback(()=>a({necessary:!0,external:!1,analytics:!1}),[a]),d=p.useCallback(y=>a({necessary:!0,external:!!y.external,analytics:!!y.analytics}),[a]),f=p.useCallback(()=>o(!0),[]),h=p.useCallback(()=>o(!1),[]);return l.jsx(xx.Provider,{value:{consent:t,decided:r,settingsOpen:i,acceptAll:u,rejectNonEssential:c,saveCustom:d,openSettings:f,closeSettings:h},children:e})}function Yr(){return p.useContext(xx)}const gT=["mon","tue","wed","thu","fri","sat","sun"],yT=["sun","mon","tue","wed","thu","fri","sat"],ll={mon:"Mo",tue:"Di",wed:"Mi",thu:"Do",fri:"Fr",sat:"Sa",sun:"So"};function xT(e){const t=new Date,n=e==null?void 0:e[yT[t.getDay()]];if(!n||n.closed||!n.open||!n.close)return!1;const r=t.getHours()*60+t.getMinutes(),[s,i]=n.open.split(":").map(Number),[o,a]=n.close.split(":").map(Number);return r>=s*60+i&&r{const s=vT(e==null?void 0:e[r])||t,i=n[n.length-1];i&&i.label===s?i.days=`${i.firstLabel}-${ll[r]}`:n.push({key:r,days:ll[r],firstLabel:ll[r],label:s})}),n}const wT=e=>(e||"").replace(/[^\d+]/g,"");function kT(){const{phone:e,contact_email:t,address_street:n,address_zip:r,address_city:s,business_hours:i,has_downloads:o}=Lt(),a=da(),u=o&&!a("page.downloads"),c=xT(i),{openSettings:d}=Yr(),{pathname:f}=nt(),h=f==="/",{t:y}=rt(),x=[n,[r,s].filter(Boolean).join(" ")].filter(Boolean).join(", "),w=`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(x)}`,b=vx(i,y("footer.closed"));return l.jsxs("footer",{className:`border-t border-neutral-200 bg-neutral-50 py-10 text-sm text-neutral-600 dark:border-neutral-800 dark:bg-neutral-950 dark:text-neutral-300 ${h?"pb-24":""}`,children:[l.jsxs("div",{className:"mx-auto grid max-w-6xl gap-4 px-4 sm:grid-cols-3 sm:px-6",children:[l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"mb-3 flex items-center gap-2",children:[l.jsx(cx,{className:"h-4 w-4 text-brand-500"}),l.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:"HifiPlanet"})]}),n&&l.jsx("p",{children:n}),(r||s)&&l.jsx("p",{children:[r,s].filter(Boolean).join(" ")}),l.jsxs("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"mt-4 flex items-center justify-center gap-1.5 rounded-md bg-brand-500 px-3 py-2 text-xs font-semibold text-white hover:bg-brand-600",children:[l.jsx(VC,{className:"h-3.5 w-3.5"}),y("footer.routePlan")]})]}),l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"mb-3 flex items-center gap-2",children:[l.jsx(Or,{className:"h-4 w-4 text-brand-500"}),l.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:y("footer.contactHeading")})]}),l.jsx("p",{children:l.jsx("a",{href:`tel:${wT(e)}`,className:"inline-block py-1 hover:text-brand-500",children:e})}),l.jsx("p",{children:l.jsx("a",{href:`mailto:${t}`,className:"inline-block py-1 hover:text-brand-500",children:t})}),l.jsx(W,{to:"/kontakt",className:"mt-4 flex items-center justify-center gap-1.5 rounded-md border border-neutral-300 px-3 py-2 text-xs font-semibold text-neutral-700 hover:border-brand-500 hover:text-brand-600 dark:border-neutral-700 dark:text-neutral-200",children:y("footer.contactForm")})]}),l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"mb-3 flex items-center justify-between gap-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(ux,{className:"h-4 w-4 text-brand-500"}),l.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:y("footer.hoursHeading")})]}),l.jsxs("span",{className:`flex items-center gap-1.5 rounded-full px-2 py-0.5 text-[11px] font-semibold ${c?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-neutral-100 text-neutral-500 dark:bg-neutral-800 dark:text-neutral-400"}`,children:[l.jsx("span",{className:`h-1.5 w-1.5 rounded-full ${c?"bg-green-500":"bg-neutral-400"}`}),y(c?"footer.open":"footer.closed")]})]}),l.jsx("dl",{className:"space-y-1.5",children:b.map(m=>l.jsxs("div",{className:"flex items-center justify-between gap-3",children:[l.jsx("dt",{className:"text-neutral-500 dark:text-neutral-400",children:m.days}),l.jsx("dd",{className:"font-medium text-neutral-700 dark:text-neutral-200",children:m.label})]},m.key))})]})]}),l.jsx("div",{className:"mx-auto mt-8 max-w-6xl border-t border-neutral-200 px-4 pt-6 text-center text-xs text-neutral-500 dark:border-neutral-800 dark:text-neutral-400 sm:px-6",children:l.jsxs("p",{className:"flex flex-wrap items-center justify-center gap-x-2 gap-y-1",children:[l.jsx("span",{children:y("footer.copyright")(new Date().getFullYear())}),l.jsx("span",{children:"·"}),l.jsx(W,{to:"/impressum",className:"hover:text-brand-500",children:y("footer.imprint")}),l.jsx("span",{children:"·"}),l.jsx(W,{to:"/datenschutz",className:"hover:text-brand-500",children:y("footer.privacy")}),l.jsx("span",{children:"·"}),l.jsx(W,{to:"/agb",className:"hover:text-brand-500",children:y("footer.terms")}),l.jsx("span",{children:"·"}),u&&l.jsxs(l.Fragment,{children:[l.jsx(W,{to:"/downloads",className:"hover:text-brand-500",children:y("footer.downloads")}),l.jsx("span",{children:"·"})]}),l.jsx("button",{type:"button",onClick:d,className:"hover:text-brand-500",children:y("footer.cookieSettings")})]})})]})}function bT(){const{scrollYProgress:e}=sx(),t=Ij(e,{stiffness:200,damping:30,restDelta:.001});return l.jsx(Kt.div,{style:{scaleX:t},className:"fixed left-0 top-0 z-40 h-0.5 w-full origin-left bg-brand-500"})}const ST=()=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",className:"h-10 w-10",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M14.7 6.3a4 4 0 0 0-5.5 4.5L3 17l2 2 6.2-6.2a4 4 0 0 0 4.5-5.5l-2.6 2.6-2-2 2.6-2.6Z"})});function oi({message:e,fullScreen:t=!1}){const{t:n}=rt(),r=l.jsxs("div",{className:"mx-auto max-w-md text-center",children:[l.jsx("div",{className:"mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-brand-100 text-brand-600 dark:bg-brand-900/40 dark:text-brand-400",children:l.jsx(ST,{})}),l.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:n("maintenance.title")}),l.jsx("p",{className:"text-neutral-600 dark:text-neutral-300",children:e||n("maintenance.defaultMessage")})]});return t?l.jsxs("div",{className:"relative flex min-h-screen items-center justify-center bg-white px-4 dark:bg-neutral-950",children:[r,l.jsxs(W,{to:"/admin/login","aria-label":n("maintenance.login"),title:n("maintenance.login"),className:"fixed bottom-4 right-4 flex items-center gap-2 rounded-full border border-neutral-200 bg-white px-3 py-2 text-sm font-medium text-neutral-600 shadow-sm transition hover:border-brand-500 hover:text-brand-600 dark:border-neutral-800 dark:bg-neutral-900 dark:text-neutral-300 dark:hover:text-brand-400",children:[l.jsx(_C,{className:"h-4 w-4"}),n("maintenance.login")]})]}):l.jsx("div",{className:"mx-auto max-w-6xl px-4 py-20 sm:px-6",children:r})}const Cm=l.jsx(l.Fragment,{children:'Wartungsmodus aktiv – Besucher sehen aktuell eine Wartungsmeldung. Du siehst diese Seite nur, weil du die Berechtigung "Wartungsmodus umgehen" hast.'});function ai({inline:e=!1}){return e?l.jsx("div",{className:"mb-8 rounded-lg bg-amber-500 px-4 py-2 text-center text-xs font-semibold text-white",children:Cm}):l.jsx("div",{className:"bg-amber-500 px-4 py-2 text-center text-xs font-semibold text-white",children:Cm})}const Tm='a[href], button:not([disabled]), input:not([disabled]), select, textarea, [tabindex]:not([tabindex="-1"])';function wx(e,t,n){p.useEffect(()=>{if(!t)return;const r=document.activeElement,s=document.body.style.overflow;document.body.style.overflow="hidden";const i=setTimeout(()=>{var a,u;return(u=(a=e.current)==null?void 0:a.querySelector(Tm))==null?void 0:u.focus()},30),o=a=>{if(a.key==="Escape"){a.stopPropagation(),n==null||n();return}if(a.key!=="Tab"||!e.current)return;const u=[...e.current.querySelectorAll(Tm)];if(!u.length)return;const c=u[0],d=u[u.length-1];a.shiftKey&&document.activeElement===c?(a.preventDefault(),d.focus()):!a.shiftKey&&document.activeElement===d&&(a.preventDefault(),c.focus())};return document.addEventListener("keydown",o),()=>{clearTimeout(i),document.body.style.overflow=s,document.removeEventListener("keydown",o),r instanceof HTMLElement&&r.focus({preventScroll:!0})}},[t,e])}function PT({onClose:e}){const{consent:t,saveCustom:n}=Yr(),[r,s]=p.useState(t.external),[i,o]=p.useState(t.analytics),{t:a}=rt(),u=p.useRef(null);return wx(u,!0,e),l.jsx("div",{className:"fixed inset-0 z-[60] flex items-center justify-center bg-black/50 p-4",onClick:e,children:l.jsxs("div",{ref:u,role:"dialog","aria-modal":"true","aria-label":a("cookieConsent.modalTitle"),className:"w-full max-w-md rounded-xl bg-white p-6 dark:bg-neutral-900",onClick:c=>c.stopPropagation(),children:[l.jsx("h2",{className:"mb-1 text-lg font-bold text-neutral-900 dark:text-white",children:a("cookieConsent.modalTitle")}),l.jsxs("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:[a("cookieConsent.modalIntro")," ",l.jsx(W,{to:"/datenschutz",className:"underline hover:text-brand-500",onClick:e,children:a("cookieConsent.privacyPolicy")}),"."]}),l.jsxs("div",{className:"space-y-3",children:[l.jsxs("div",{className:"flex items-start justify-between gap-3 rounded-lg border border-neutral-200 p-3 dark:border-neutral-700",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-semibold text-neutral-800 dark:text-neutral-100",children:a("cookieConsent.necessaryTitle")}),l.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:a("cookieConsent.necessaryDesc")})]}),l.jsx("input",{type:"checkbox",checked:!0,disabled:!0,className:"mt-1 h-4 w-4 shrink-0"})]}),l.jsxs("div",{className:"flex items-start justify-between gap-3 rounded-lg border border-neutral-200 p-3 dark:border-neutral-700",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-semibold text-neutral-800 dark:text-neutral-100",children:a("cookieConsent.externalTitle")}),l.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:a("cookieConsent.externalDesc")})]}),l.jsx("input",{type:"checkbox",checked:r,onChange:c=>s(c.target.checked),className:"mt-1 h-4 w-4 shrink-0"})]}),l.jsxs("div",{className:"flex items-start justify-between gap-3 rounded-lg border border-neutral-200 p-3 dark:border-neutral-700",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-semibold text-neutral-800 dark:text-neutral-100",children:a("cookieConsent.analyticsTitle")}),l.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:a("cookieConsent.analyticsDesc")})]}),l.jsx("input",{type:"checkbox",checked:i,onChange:c=>o(c.target.checked),className:"mt-1 h-4 w-4 shrink-0"})]})]}),l.jsxs("div",{className:"mt-5 flex justify-end gap-2",children:[l.jsx("button",{type:"button",onClick:e,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:a("cookieConsent.cancel")}),l.jsx("button",{type:"button",onClick:()=>n({external:r,analytics:i}),className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:a("cookieConsent.saveSelection")})]})]})})}function jT(){const{decided:e,settingsOpen:t,acceptAll:n,rejectNonEssential:r,openSettings:s,closeSettings:i}=Yr(),{t:o}=rt();return l.jsxs(l.Fragment,{children:[!e&&l.jsx("div",{className:"fixed inset-x-0 bottom-0 z-50 border-t border-neutral-200 bg-white/95 p-4 shadow-lg backdrop-blur dark:border-neutral-800 dark:bg-neutral-900/95 sm:p-5",children:l.jsxs("div",{className:"mx-auto flex max-w-6xl flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[l.jsxs("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:[o("cookieConsent.bannerText")," ",o("cookieConsent.moreInfo")," ",l.jsx(W,{to:"/datenschutz",className:"underline hover:text-brand-500",children:o("cookieConsent.privacyPolicy")}),"."]}),l.jsxs("div",{className:"flex flex-wrap gap-2 sm:shrink-0",children:[l.jsx("button",{type:"button",onClick:s,className:"rounded-md border border-neutral-300 px-3 py-2 text-sm dark:border-neutral-700",children:o("cookieConsent.settings")}),l.jsx("button",{type:"button",onClick:r,className:"rounded-md border border-neutral-300 px-3 py-2 text-sm dark:border-neutral-700",children:o("cookieConsent.onlyNecessary")}),l.jsx("button",{type:"button",onClick:n,className:"rounded-md bg-brand-500 px-3 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:o("cookieConsent.acceptAll")})]})]})}),t&&l.jsx(PT,{onClose:i})]})}function CT(){const{consent:e}=Yr(),{ga_measurement_id:t}=Lt(),n=p.useRef(!1),r=nt();return p.useEffect(()=>{if(!t||!e.analytics||n.current)return;n.current=!0;const s=document.createElement("script");s.src=`https://www.googletagmanager.com/gtag/js?id=${t}`,s.async=!0,document.head.appendChild(s),window.dataLayer=window.dataLayer||[];function i(...o){window.dataLayer.push(o)}window.gtag=i,i("js",new Date),i("config",t,{anonymize_ip:!0,send_page_view:!1})},[t,e.analytics]),p.useEffect(()=>{!n.current||typeof window.gtag!="function"||window.gtag("consent","update",{analytics_storage:e.analytics?"granted":"denied"})},[e.analytics]),p.useEffect(()=>{!e.analytics||typeof window.gtag!="function"||window.gtag("event","page_view",{page_path:r.pathname+r.search,page_location:window.location.href,page_title:document.title})},[r.pathname,r.search,e.analytics,t]),null}const kx=p.createContext({global:{enabled:!1,message:null},services:{enabled:!1,message:null},vehicles:{enabled:!1,message:null},bypass:!1}),TT=kx.Provider;function fa(){return p.useContext(kx)}const jd=p.createContext({}),ET=jd.Provider;function Jn(e,t){const n=e[t];if(!n)return{};const r={};return n.font_family&&(r.fontFamily=n.font_family),n.font_size&&(r.fontSize=n.font_size),n.color&&(r.color=n.color),r}function Be(e){const t=p.useContext(jd);return Jn(t,e)}function Cd(){return p.useContext(jd)}const NT=[{label:"Systemschrift",value:""},{label:"Serifenlos (Arial)",value:"Arial, Helvetica, sans-serif"},{label:"Serif (Georgia)",value:'Georgia, "Times New Roman", serif'},{label:"Klassisch (Times New Roman)",value:'"Times New Roman", Times, serif'},{label:"Modern (Verdana)",value:"Verdana, Geneva, sans-serif"},{label:"Schreibmaschine (Courier New)",value:'"Courier New", Courier, monospace'}],Td=p.createContext({fonts:[],refresh:()=>{}}),bx=Td.Provider;function Sx(){return p.useContext(Td).fonts}function MN(){return p.useContext(Td).refresh}function LN(){const e=Sx();return[...NT,...e.map(t=>({label:t.name,value:t.font_family}))]}function _T(e){const t=/\.([a-z0-9]+)$/i.exec(e||"");return t?t[1].toLowerCase():""}const MT={woff2:"woff2",woff:"woff",ttf:"truetype",otf:"opentype"};function Px(){const e=Sx();if(e.length===0)return null;const t=e.map(n=>{const r=MT[_T(n.file_path)]||"woff2";return`@font-face { font-family: "${n.font_family}"; src: url("${n.file_path}") format("${r}"); font-display: swap; }`}).join(` +`);return l.jsx("style",{children:t})}const LT=150,AT=300,DT=80,RT=5e3;function IT(){return l.jsx("div",{className:"fixed inset-0 z-[200] flex items-center justify-center bg-white dark:bg-neutral-950",children:l.jsx("div",{className:"h-10 w-10 animate-spin rounded-full border-4 border-neutral-200 border-t-brand-500 dark:border-neutral-800 dark:border-t-brand-500"})})}function VT({enabled:e,children:t}){const n=nt(),[r,s]=p.useState(!e),[i,o]=p.useState(!1),a=p.useRef(null);return p.useLayoutEffect(()=>{const u=a.current;if(!e||!u){s(!0),o(!1);return}s(!1),o(!1);let c=!1,d=0,f=null;const h=new Set,y=setTimeout(()=>{d=Date.now(),o(!0)},LT),x=()=>{s(!0),o(!1)},w=()=>{c=!0,clearTimeout(y),clearTimeout(f),clearTimeout(C),k.disconnect(),S()},b=()=>{if(c)return;w();const j=d?AT-(Date.now()-d):0;j>0?setTimeout(x,j):x()},m=()=>{clearTimeout(f),f=setTimeout(()=>{h.size===0&&$j()===0&&b()},DT)},g=j=>{if(h.has(j)||j.complete||j.getBoundingClientRect().top>=window.innerHeight)return;j.loading==="lazy"&&(j.loading="eager"),h.add(j);const P=()=>{h.delete(j),j.removeEventListener("load",P),j.removeEventListener("error",P),m()};j.addEventListener("load",P),j.addEventListener("error",P)},v=j=>{var P;j.nodeType===1&&(j.tagName==="IMG"&&g(j),(P=j.querySelectorAll)==null||P.call(j,"img").forEach(g))},k=new MutationObserver(j=>{j.forEach(P=>P.addedNodes.forEach(v)),m()});k.observe(u,{childList:!0,subtree:!0});const S=Uj(m),C=setTimeout(b,RT);return u.querySelectorAll("img").forEach(g),m(),()=>{c||w()}},[n.pathname,e]),l.jsxs("div",{className:"relative",children:[l.jsx("div",{ref:a,style:e?{visibility:r?"visible":"hidden"}:void 0,children:t}),e&&i&&l.jsx(IT,{})]})}const jx=[{title:"Seiten",hint:"Ausgeblendete Seiten verschwinden aus dem Menü und leiten Besucher auf die Startseite um.",areas:[{key:"page.vehicles",label:"Fahrzeuge & Pakete",path:"/fahrzeuge"},{key:"page.services",label:"Leistungen",path:"/leistungen"},{key:"page.gallery",label:"Galerie",path:"/galerie"},{key:"page.downloads",label:"Downloads",path:"/downloads",note:"Erscheint ohnehin nur, wenn Downloads hinterlegt sind."}]},{title:"Startseite",hint:"Einzelne Abschnitte der Startseite. Das große Titelbild oben bleibt immer sichtbar.",areas:[{key:"home.stats",label:"Zahlen-Leiste"},{key:"home.partners",label:"Marken / Partner-Logos"},{key:"home.youtube",label:"Video-Abschnitt"},{key:"home.craft",label:"Handwerk & Beratung"},{key:"home.insights",label:"Einblicke (Bilder)"},{key:"home.reviews",label:"Kundenbewertungen"},{key:"home.more",label:'„Mehr als Car-Hifi"'},{key:"home.faq",label:"Häufige Fragen (FAQ)"}]}],FT=jx[0].areas;function OT(e){if(!e)return null;const t=FT.find(n=>e===n.path||e.startsWith(`${n.path}/`));return t?t.key:null}function Cx(e,t=[]){const n=OT(e);return!!n&&t.includes(n)}const zT=jx.flatMap(e=>e.areas),BT={global:{enabled:!1,message:null},services:{enabled:!1,message:null},vehicles:{enabled:!1,message:null}},HT={mon:{open:"09:00",close:"18:00",closed:!1},tue:{open:"09:00",close:"18:00",closed:!1},wed:{open:"09:00",close:"18:00",closed:!1},thu:{open:"09:00",close:"18:00",closed:!1},fri:{open:"09:00",close:"18:00",closed:!1},sat:{open:"10:00",close:"13:00",closed:!1},sun:{open:"",close:"",closed:!0}},ul={phone:"09373 20 62 390",whatsapp:null,contact_email:"info@hifi-planet-amorbach.de",address_street:"Boxbrunner Str. 20a",address_zip:"63916",address_city:"Amorbach",logo_path:null,logo_dark_path:null,business_hours:HT,hero_image_path:null,ga_measurement_id:null,package_card_theme:"graphite",package_card_layout:"strip",package_wheel_hint_interval:8,package_card_width:210,package_card_height:480,vehicle_tile_width:240,vehicle_tile_height:180,gallery_card_text_x:0,gallery_card_text_y:100,site_font:null,page_loader_enabled:1,has_downloads:!1,hidden_areas:[],price_note:null,price_note_en:null},$T=["/impressum","/datenschutz","/agb"],Em="hifi-site-settings",Nm="hifi-maintenance";function _m(e){try{const t=localStorage.getItem(e);return t?JSON.parse(t):null}catch{return null}}function Mm(e,t){try{localStorage.setItem(e,JSON.stringify(t))}catch{}}const UT={mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday",sun:"Sunday"};function WT(e){var n,r,s;const t=document.getElementById("ld-business");if(t)try{const i=JSON.parse(t.textContent),o=(e.phone||"").replace(/[^\d+]/g,"");o&&(i.telephone=o.startsWith("+")?o:`+49${o.replace(/^0/,"")}`),e.contact_email&&(i.email=e.contact_email),i.address={"@type":"PostalAddress",streetAddress:e.address_street||((n=i.address)==null?void 0:n.streetAddress),postalCode:e.address_zip||((r=i.address)==null?void 0:r.postalCode),addressLocality:e.address_city||((s=i.address)==null?void 0:s.addressLocality),addressCountry:"DE"};const a=e.business_hours;a&&typeof a=="object"&&(i.openingHoursSpecification=Object.entries(UT).filter(([u])=>a[u]&&!a[u].closed&&a[u].open&&a[u].close).map(([u,c])=>({"@type":"OpeningHoursSpecification",dayOfWeek:c,opens:a[u].open,closes:a[u].close}))),t.textContent=JSON.stringify(i)}catch{}}function GT(){var b;const[e]=p.useState(()=>_m(Em)),[t,n]=p.useState(()=>_m(Nm)),[r,s]=p.useState(()=>e?{...ul,...e}:ul),[i,o]=p.useState(!!e),[a,u]=p.useState({}),[c,d]=p.useState([]),{loading:f,hasPermission:h}=qr(),y=nt();if(p.useEffect(()=>{ce.get("/maintenance").then(m=>{n(m),Mm(Nm,m)}).catch(()=>n(m=>m||BT)),ce.get("/site-settings").then(m=>{s({...ul,...m}),Mm(Em,m)}).catch(()=>{}).finally(()=>o(!0)),ce.get("/text-styles").then(u).catch(()=>{}),ce.get("/custom-fonts").then(d).catch(()=>{})},[]),p.useEffect(()=>{r.site_font?document.documentElement.style.setProperty("--site-font",r.site_font):document.documentElement.style.removeProperty("--site-font")},[r.site_font]),p.useEffect(()=>{i&&WT(r)},[r,i]),t===null||!i||(b=t.global)!=null&&b.enabled&&f)return l.jsx("div",{className:"min-h-screen bg-white dark:bg-neutral-950"});const x=h("maintenance.bypass"),w=$T.includes(y.pathname);return t.global.enabled&&!x&&!w?l.jsx(Sm,{children:l.jsx(oi,{message:t.global.message,fullScreen:!0})}):l.jsx(Sm,{children:l.jsx(TT,{value:{...t,bypass:x},children:l.jsx(lT,{value:r,children:l.jsx(ET,{value:a,children:l.jsx(bx,{value:{fonts:c,refresh:()=>{}},children:l.jsxs("div",{className:"page-texture flex min-h-screen flex-col text-neutral-900 dark:text-neutral-100",children:[l.jsx(Px,{}),x&&t.global.enabled&&l.jsx(ai,{}),l.jsx(bT,{}),l.jsx(mT,{}),l.jsx("main",{className:"flex-1",children:l.jsx(VT,{enabled:y.pathname!=="/"&&!!r.page_loader_enabled,children:Cx(y.pathname,r.hidden_areas)?l.jsx(Zn,{to:"/",replace:!0}):l.jsx(p.Suspense,{fallback:l.jsx("div",{className:"min-h-[60vh]"}),children:l.jsx(Hc,{})})})}),l.jsx(kT,{}),l.jsx(jT,{}),l.jsx(CT,{})]})})})})})})}const ha=p.createContext({toast:{success:()=>{},error:()=>{},info:()=>{}},setDirty:()=>{},confirmLeave:()=>!0,refreshCounters:()=>{}});let KT=0;function qT({children:e,onRefreshCounters:t}){const[n,r]=p.useState([]),s=p.useRef(new Set),i=p.useCallback(f=>r(h=>h.filter(y=>y.id!==f)),[]),o=p.useCallback((f,h,y={})=>{const x=++KT;return r(w=>[...w.slice(-3),{id:x,type:f,message:h,action:y.action}]),setTimeout(()=>i(x),y.duration||(f==="error"?7e3:3500)),x},[i]),a=p.useMemo(()=>({success:(f,h)=>o("success",f,h),error:(f,h)=>o("error",f,h),info:(f,h)=>o("info",f,h)}),[o]),u=p.useCallback((f,h)=>{h?s.current.add(f):s.current.delete(f)},[]),c=p.useCallback(()=>{if(s.current.size===0)return!0;const f=window.confirm("Du hast ungespeicherte Änderungen. Seite trotzdem verlassen? Die Änderungen gehen dann verloren.");return f&&s.current.clear(),f},[]);p.useEffect(()=>{const f=y=>{s.current.size!==0&&(y.preventDefault(),y.returnValue="")},h=y=>{var b,m;if(s.current.size===0||y.defaultPrevented||y.button!==0)return;const x=(m=(b=y.target).closest)==null?void 0:m.call(b,"a[href]");if(!x||x.target==="_blank"||y.metaKey||y.ctrlKey||y.shiftKey)return;const w=new URL(x.href,window.location.href);w.origin!==window.location.origin||w.pathname===window.location.pathname||c()||(y.preventDefault(),y.stopPropagation())};return window.addEventListener("beforeunload",f),document.addEventListener("click",h,!0),()=>{window.removeEventListener("beforeunload",f),document.removeEventListener("click",h,!0)}},[c]);const d=p.useMemo(()=>({toast:a,setDirty:u,confirmLeave:c,refreshCounters:t||(()=>{})}),[a,u,c,t]);return l.jsxs(ha.Provider,{value:d,children:[e,l.jsx("div",{className:"pointer-events-none fixed bottom-4 right-4 z-[300] flex w-[min(92vw,380px)] flex-col gap-2","aria-live":"polite",children:n.map(f=>l.jsxs("div",{role:f.type==="error"?"alert":"status",className:`pointer-events-auto flex items-start justify-between gap-3 rounded-lg border px-4 py-3 text-sm shadow-lg ${f.type==="error"?"border-red-200 bg-red-50 text-red-800 dark:border-red-900 dark:bg-red-950 dark:text-red-200":f.type==="success"?"border-green-200 bg-green-50 text-green-800 dark:border-green-900 dark:bg-green-950 dark:text-green-200":"border-neutral-200 bg-white text-neutral-800 dark:border-neutral-700 dark:bg-neutral-900 dark:text-neutral-100"}`,children:[l.jsxs("span",{children:[f.type==="success"?"✓ ":"",f.message]}),l.jsxs("span",{className:"flex shrink-0 items-center gap-3",children:[f.action&&l.jsx("button",{type:"button",onClick:()=>{f.action.onClick(),i(f.id)},className:"font-semibold underline",children:f.action.label}),l.jsx("button",{type:"button",onClick:()=>i(f.id),"aria-label":"Meldung schließen",className:"opacity-60 hover:opacity-100",children:"✕"})]})]},f.id))})]})}function AN(){return p.useContext(ha)}function DN(){return p.useContext(ha).toast}function RN(e,t="page"){const{setDirty:n}=p.useContext(ha);p.useEffect(()=>{n(t,!!e)},[e,t,n]),p.useEffect(()=>()=>n(t,!1),[t,n])}const YT=5*60*1e3,XT=30*60*1e3;function ZT(){const{user:e,login:t,verifyTwoFactor:n}=qr(),[r,s]=p.useState(!1),[i,o]=p.useState("credentials"),[a,u]=p.useState((e==null?void 0:e.username)||""),[c,d]=p.useState(""),[f,h]=p.useState(""),[y,x]=p.useState(""),[w,b]=p.useState(!1),m=p.useRef(Date.now()),g=p.useRef(null);if(wx(g,r,()=>{}),p.useEffect(()=>Wj(()=>s(!0)),[]),p.useEffect(()=>{const j=()=>{m.current=Date.now()},P=["keydown","pointerdown","scroll"];P.forEach(E=>window.addEventListener(E,j,{passive:!0}));const M=setInterval(()=>{document.hidden||Date.now()-m.current>XT||ce.get("/auth/me").then(E=>{(E==null?void 0:E.authenticated)===!1&&s(!0)}).catch(()=>{})},YT);return()=>{P.forEach(E=>window.removeEventListener(E,j)),clearInterval(M)}},[]),!r)return null;const v=()=>{s(!1),o("credentials"),d(""),h(""),x("")},k=async j=>{j.preventDefault(),b(!0),x("");try{(await t(a,c)).requires2fa?o("code"):v()}catch(P){x(P.message)}finally{b(!1)}},S=async j=>{j.preventDefault(),b(!0),x("");try{await n(f),v()}catch(P){x(P.message)}finally{b(!1)}},C="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900";return l.jsx("div",{className:"fixed inset-0 z-[400] flex items-center justify-center bg-black/50 p-4",children:l.jsxs("div",{ref:g,role:"dialog","aria-modal":"true","aria-labelledby":"session-expired-title",className:"w-full max-w-sm rounded-xl bg-white p-6 shadow-xl dark:bg-neutral-900",children:[l.jsx("h2",{id:"session-expired-title",className:"mb-1 text-lg font-bold text-neutral-900 dark:text-white",children:"Bitte erneut anmelden"}),l.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Deine Sitzung ist abgelaufen. Deine Eingaben auf dieser Seite bleiben erhalten – nach dem Anmelden einfach noch einmal speichern."}),i==="credentials"?l.jsxs("form",{onSubmit:k,className:"space-y-3",children:[l.jsx("input",{value:a,onChange:j=>u(j.target.value),required:!0,placeholder:"Benutzername",autoComplete:"username",className:C}),l.jsx("input",{type:"password",value:c,onChange:j=>d(j.target.value),required:!0,placeholder:"Passwort",autoComplete:"current-password",className:C}),y&&l.jsx("p",{className:"text-sm text-red-600",children:y}),l.jsx("button",{type:"submit",disabled:w,className:"w-full rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:w?"Melde an…":"Anmelden"})]}):l.jsxs("form",{onSubmit:S,className:"space-y-3",children:[l.jsx("input",{value:f,onChange:j=>h(j.target.value),required:!0,inputMode:"numeric",autoComplete:"one-time-code",placeholder:"6-stelliger Code aus der App",className:C}),y&&l.jsx("p",{className:"text-sm text-red-600",children:y}),l.jsx("button",{type:"submit",disabled:w,className:"w-full rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:w?"Prüfe…":"Bestätigen"})]})]})})}const Lm="/assets/logo-BNfZDkmN.png",Am={home:"M3 11.5 12 4l9 7.5M5 10v9a1 1 0 0 0 1 1h4v-6h4v6h4a1 1 0 0 0 1-1v-9",tag:"M4 4h7l9 9-7 7-9-9V4Zm3.5 3.5h.01",car:"M3 13.5 4.5 9A2 2 0 0 1 6.4 7.5h11.2A2 2 0 0 1 19.5 9L21 13.5M3 13.5v4a1 1 0 0 0 1 1h1a1 1 0 0 0 1-1v-1h12v1a1 1 0 0 0 1 1h1a1 1 0 0 0 1-1v-4M3 13.5h18M6.5 16.5h.01M17.5 16.5h.01",box:"M12 3 4 7.5v9L12 21l8-4.5v-9L12 3Zm0 9 8-4.5M12 12v9M12 12 4 7.5",mail:"M4 6h16a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1Zm0 0 8 7 8-7",users:"M16 7a4 4 0 1 1-8 0 4 4 0 0 1 8 0Zm-4 6c-4 0-7 2-7 4.5V19h14v-1.5C19 15 16 13 12 13Z",shield:"M12 3 4 6v6c0 4.5 3.4 7.7 8 9 4.6-1.3 8-4.5 8-9V6l-8-3Zm-1.5 9.5 4-4 1 1-5 5-2.5-2.5 1-1 1.5 1.5Z",lock:"M6 10V8a6 6 0 1 1 12 0v2m-13 0h14a1 1 0 0 1 1 1v9a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-9a1 1 0 0 1 1-1Zm7 5v2",briefcase:"M4 7h16a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V8a1 1 0 0 1 1-1Zm4 0V5a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2M3 12h18",sliders:"M4 6h16M4 6a2 2 0 1 0 4 0 2 2 0 0 0-4 0Zm16 6H4m10 0a2 2 0 1 0 4 0 2 2 0 0 0-4 0ZM4 18h16m-12 0a2 2 0 1 0 4 0 2 2 0 0 0-4 0Z",image:"M4 5h16a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V6a1 1 0 0 1 1-1Zm2 12 4.5-5.5L14 16l2.5-3L20 17H6ZM8 9.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z",help:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm0-5.5v.01M9.5 9.25a2.5 2.5 0 1 1 3.5 2.29c-.7.32-1 .77-1 1.46v.3",download:"M12 4v11m0 0-4-4m4 4 4-4M5 19h14",gauge:"M4 13a8 8 0 1 1 16 0M12 13l3.5-3.5M6 17h12",inbox:"M3 13h5l1.5 2.5h5L16 13h5M5 5h14l2 8v5a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1v-5l2-8Z",building:"M4 21V5a1 1 0 0 1 1-1h9a1 1 0 0 1 1 1v16M15 9h4a1 1 0 0 1 1 1v11M3 21h18M8 8h3M8 12h3M8 16h3",palette:"M12 3a9 9 0 1 0 0 18c1 0 1.5-.7 1.5-1.5 0-.4-.2-.8-.4-1.1-.3-.3-.4-.7-.4-1.1 0-.8.7-1.5 1.5-1.5H16a5 5 0 0 0 5-5c0-4.4-4-7.8-9-7.8ZM7.5 12h.01M10 7.5h.01M15 7.5h.01",file:"M7 3h7l5 5v12a1 1 0 0 1-1 1H7a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1Zm7 0v5h5M9 13h6M9 17h6",wrench:"M14.5 6.5a4 4 0 0 0-5.3 5.3L4 17l3 3 5.2-5.2a4 4 0 0 0 5.3-5.3l-2.5 2.5-2.5-.5-.5-2.5 2.5-2.5Z",server:"M4 4h16v6H4V4Zm0 10h16v6H4v-6Zm3-7h.01M7 17h.01",globe:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm-9-9h18M12 3c2.5 2.5 3.5 5.5 3.5 9s-1 6.5-3.5 9c-2.5-2.5-3.5-5.5-3.5-9s1-6.5 3.5-9Z",send:"M4 12 20 4l-4 16-4-7-8-1Zm8 1 8-9",refresh:"M20 11a8 8 0 0 0-14.9-3M4 4v4h4m-4 5a8 8 0 0 0 14.9 3M20 20v-4h-4",trash:"M5 7h14M10 11v6m4-6v6M6 7l1 13h10l1-13M9 7V4h6v3",external:"M14 4h6v6m0-6-9 9M19 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V6a1 1 0 0 1 1-1h5",pause:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm-2-12v6m4-6v6"},Dm=({path:e})=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",className:"h-5 w-5 shrink-0",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:e})});function QT(){const{logout:e,user:t,hasPermission:n}=qr(),r=sa(),[s,i]=p.useState(!1),[o,a]=p.useState(0),[u,c]=p.useState([]),[d,f]=p.useState([]),[h,y]=p.useState(!1),x=p.useCallback(()=>{n("contact.manage")&&ce.get("/contact").then(S=>a(S.filter(C=>C.status==="new").length)).catch(()=>{}),ce.get("/site-settings").then(S=>f(S.hidden_areas||[])).catch(()=>{}),ce.get("/maintenance").then(S=>{var C;return y(!!((C=S==null?void 0:S.global)!=null&&C.enabled))}).catch(()=>{})},[t==null?void 0:t.id]);p.useEffect(()=>{x();const S=setInterval(x,2*60*1e3);return()=>clearInterval(S)},[x]);const w=zT.filter(S=>d.includes(S.key)).map(S=>S.label),b=()=>ce.get("/custom-fonts").then(c).catch(()=>{});p.useEffect(()=>{b()},[]);const m=[{title:null,links:[{to:"/admin",label:"Übersicht",icon:"gauge",end:!0},{to:"/admin/contact-requests",label:"Anfragen",icon:"inbox",permission:"contact.manage",badge:o}]},{title:"Fahrzeuge & Pakete",links:[{to:"/admin/brands",label:"Fahrzeugmarken",icon:"tag",permission:"brands.manage"},{to:"/admin/models",label:"Modelle",icon:"car",permission:"models.manage"},{to:"/admin/packages",label:"Pakete",icon:"box",permission:"packages.manage"}]},{title:"Website-Inhalte",links:[{to:"/admin/home-sections",label:"Startseite",icon:"home",permission:"content.manage"},{to:"/admin/services",label:"Leistungen",icon:"briefcase",permission:"services.manage"},{to:"/admin/faqs",label:"FAQ",icon:"help",permission:"content.manage"},{to:"/admin/partners",label:"Partner-Logos",icon:"shield",permission:"content.manage"},{to:"/admin/downloads",label:"Downloads",icon:"download",permission:"downloads.manage"}]},{title:"Bildergalerie",links:[{to:"/admin/gallery-brands",label:"Galerie-Marken",icon:"image",permission:"gallery.manage"},{to:"/admin/gallery-projects",label:"Projekte & Fotos",icon:"image",permission:"gallery.manage"}]},{title:"Firma & Aussehen",links:[{to:"/admin/settings/company",label:"Firmendaten",icon:"building",permission:"settings.manage"},{to:"/admin/settings/design",label:"Aussehen",icon:"palette",permission:"settings.manage"},{to:"/admin/settings/legal",label:"Rechtstexte",icon:"file",permission:"settings.manage"},{to:"/admin/settings/maintenance",label:"Wartungsmodus",icon:"pause",permission:"settings.manage"}]},{title:"System (Experten)",links:[{to:"/admin/users",label:"Benutzer",icon:"users",permission:"users.manage"},{to:"/admin/permission-groups",label:"Berechtigungsgruppen",icon:"lock",permission:"permission_groups.manage"},{to:"/admin/settings/email",label:"E-Mail-Versand",icon:"send",permission:"system.admin"},{to:"/admin/settings/google",label:"Google-Dienste",icon:"globe",permission:"system.admin"},{to:"/admin/settings/database",label:"Datenbank",icon:"server",permission:"system.admin"},{to:"/admin/settings/export-import",label:"Export & Import",icon:"download",permission:"system.admin"},{to:"/admin/settings/update",label:"Updates",icon:"refresh",permission:"system.update"},{to:"/admin/settings/reset",label:"Zurücksetzen",icon:"trash",permission:"system.admin"}]},{title:null,links:[{to:"/admin/account",label:"Mein Konto",icon:"lock"}]}].map(S=>({...S,links:S.links.filter(C=>!C.permission||n(C.permission))})).filter(S=>S.links.length>0),g=async()=>{await e(),r("/admin/login")},v=({isActive:S})=>`flex items-center justify-between gap-2 rounded-md px-3 py-2 text-sm font-medium transition ${S?"bg-brand-500 text-white":"text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,k=({onNavigate:S})=>l.jsx("nav",{className:"space-y-5",children:m.map((C,j)=>l.jsxs("div",{children:[C.title&&l.jsx("p",{className:"mb-1.5 px-3 text-xs font-semibold uppercase tracking-wide text-neutral-400 dark:text-neutral-500",children:C.title}),l.jsx("div",{className:"space-y-1",children:C.links.map(P=>l.jsxs(lk,{to:P.to,end:P.end,className:v,onClick:S,children:[l.jsxs("span",{className:"flex items-center gap-2.5",children:[l.jsx(Dm,{path:Am[P.icon]}),P.label]}),!!P.badge&&l.jsx("span",{className:"rounded-full bg-red-500 px-2 py-0.5 text-xs font-bold text-white",children:P.badge})]},P.to))})]},j))});return l.jsxs(qT,{onRefreshCounters:x,children:[l.jsx(ZT,{}),l.jsx(bx,{value:{fonts:u,refresh:b},children:l.jsxs("div",{className:"flex min-h-screen bg-neutral-50 text-neutral-900 dark:bg-neutral-950 dark:text-neutral-100",children:[l.jsx(Px,{}),l.jsxs("aside",{className:"hidden w-60 shrink-0 border-r border-neutral-200 p-4 dark:border-neutral-800 sm:block",children:[l.jsxs("div",{className:"mb-6 flex items-center gap-2 px-3",children:[l.jsxs(W,{to:"/",className:"rounded-lg px-2 py-1",children:[l.jsx("img",{src:Lm,alt:"HifiPlanet",className:"h-7 w-auto dark:hidden"}),l.jsx("img",{src:Hu,alt:"HifiPlanet",className:"hidden h-7 w-auto dark:block"})]}),l.jsx("span",{className:"text-sm font-semibold text-neutral-500 dark:text-neutral-400",children:"Admin"})]}),l.jsx(k,{})]}),l.jsxs("div",{className:"flex-1",children:[l.jsxs("header",{className:"border-b border-neutral-200 dark:border-neutral-800",children:[l.jsxs("div",{className:"flex items-center justify-between px-4 py-3 sm:px-6",children:[l.jsxs("div",{className:"flex items-center gap-2 sm:hidden",children:[l.jsx("button",{onClick:()=>i(S=>!S),"aria-label":"Menü öffnen",className:"rounded-md p-2 text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800",children:l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-6 w-6",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 6h16M4 12h16M4 18h16"})})}),l.jsxs(W,{to:"/",className:"rounded-lg px-1.5 py-0.5",children:[l.jsx("img",{src:Lm,alt:"HifiPlanet",className:"h-6 w-auto dark:hidden"}),l.jsx("img",{src:Hu,alt:"HifiPlanet",className:"hidden h-6 w-auto dark:block"})]})]}),l.jsxs("p",{className:"hidden text-sm text-neutral-500 dark:text-neutral-400 sm:block",children:["Angemeldet als ",t==null?void 0:t.username,t!=null&&t.is_super_admin?" · Super-Admin":""]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsxs("a",{href:"/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:[l.jsx(Dm,{path:Am.external}),l.jsx("span",{className:"hidden sm:inline",children:"Website öffnen"})]}),l.jsx(mx,{}),l.jsx("button",{onClick:g,className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:"Abmelden"})]})]}),s&&l.jsx("div",{className:"border-t border-neutral-200 px-4 py-3 dark:border-neutral-800 sm:hidden",children:l.jsx(k,{onNavigate:()=>i(!1)})})]}),(h||w.length>0)&&l.jsxs("div",{className:"border-b border-amber-200 bg-amber-50 px-4 py-2 text-sm text-amber-900 dark:border-amber-900 dark:bg-amber-950 dark:text-amber-200 sm:px-6",children:[h&&l.jsxs("p",{children:[l.jsx("strong",{children:"Wartungsmodus ist aktiv"})," – Besucher sehen gerade nur die Wartungsseite."," ",n("settings.manage")&&l.jsx(W,{to:"/admin/settings/maintenance",className:"underline",children:"Ändern"})]}),w.length>0&&l.jsxs("p",{children:[l.jsx("strong",{children:"Ausgeblendet für Besucher:"})," ",w.join(", "),"."," ",l.jsx(W,{to:"/admin",className:"underline",children:"Auf der Übersicht ändern"})]})]}),l.jsx("main",{className:"p-4 sm:p-6",children:l.jsx(p.Suspense,{fallback:l.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),children:l.jsx(Hc,{})})})]})]})})]})}function JT(){const{user:e,loading:t}=qr();return t?l.jsx("div",{className:"flex min-h-screen items-center justify-center text-neutral-500",children:"Lädt…"}):e?l.jsx(Hc,{}):l.jsx(Zn,{to:"/admin/login",replace:!0})}function fe({permission:e,children:t}){const{hasPermission:n}=qr();return(Array.isArray(e)?e:[e]).some(i=>n(i))?t:l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-8 text-center dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsx("h1",{className:"mb-2 text-lg font-bold text-neutral-900 dark:text-white",children:"Keine Berechtigung"}),l.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:"Du hast keinen Zugriff auf diesen Bereich. Bitte wende dich an einen Administrator, falls du hier Zugriff brauchst."})]})}function Ji(e,t,n="name"){if(!t)return;let r=document.head.querySelector(`meta[${n}="${e}"]`);r||(r=document.createElement("meta"),r.setAttribute(n,e),document.head.appendChild(r)),r.setAttribute("content",t)}function eE(e){let t=document.head.querySelector('link[rel="canonical"]');t||(t=document.createElement("link"),t.setAttribute("rel","canonical"),document.head.appendChild(t)),t.setAttribute("href",`https://hifi-planet.de${e}`),Ji("og:url",`https://hifi-planet.de${e}`,"property")}function Rm(e){let t=document.head.querySelector('meta[name="robots"]');if(!e){t==null||t.remove();return}t||(t=document.createElement("meta"),t.setAttribute("name","robots"),document.head.appendChild(t)),t.setAttribute("content","noindex")}function nr({title:e,description:t,path:n,noindex:r=!1}){p.useEffect(()=>(Rm(r),()=>Rm(!1)),[r]),p.useEffect(()=>{e&&(document.title=`${e} | HifiPlanet`,Ji("og:title",`${e} | HifiPlanet`,"property")),t&&(Ji("description",t),Ji("og:description",t,"property")),n&&eE(n)},[e,t,n])}const tE=[.16,1,.3,1],Im={up:{y:40},left:{x:-56},right:{x:56}};function nE(e){return{hidden:{opacity:0,scale:.96,filter:"blur(8px)",...Im[e]||Im.up},visible:{opacity:1,scale:1,x:0,y:0,filter:"blur(0px)"}}}const rE={hidden:{x:"-130%"},visible:{x:"230%",transition:{duration:1.1,ease:"easeInOut",delay:.4}}};function ze({children:e,direction:t="up",className:n="",index:r=0,shine:s=!1,style:i}){const o=Math.min(r*.09,.45);return l.jsxs(Kt.div,{className:n,style:{position:"relative",overflow:"hidden",...i},initial:"hidden",whileInView:"visible",viewport:{once:!0,amount:.25,margin:"-100px"},variants:nE(t),transition:{duration:.75,ease:tE,delay:o},children:[e,s&&l.jsx(Kt.div,{"aria-hidden":!0,variants:rE,className:"pointer-events-none absolute inset-y-0 -left-1/3 w-1/3 rotate-12 bg-gradient-to-r from-transparent via-white/40 to-transparent"})]})}function sE({items:e}){const[t,n]=p.useState(null);return l.jsx("div",{className:"divide-y divide-neutral-200 rounded-xl border border-neutral-200 bg-white dark:divide-neutral-800 dark:border-neutral-800 dark:bg-neutral-900",children:e.map((r,s)=>{const i=t===s;return l.jsxs("div",{children:[l.jsxs("button",{onClick:()=>n(i?null:s),className:"flex w-full items-center justify-between gap-4 px-5 py-4 text-left","aria-expanded":i,children:[l.jsx("span",{className:"font-medium text-neutral-900 dark:text-white",children:r.question}),l.jsx(Kt.svg,{animate:{rotate:i?180:0},transition:{duration:.2},xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-5 w-5 shrink-0 text-neutral-500",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m6 9 6 6 6-6"})})]}),l.jsx(rP,{initial:!1,children:i&&l.jsx(Kt.div,{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.25,ease:"easeInOut"},className:"overflow-hidden",children:l.jsx("p",{className:"px-5 pb-4 text-sm text-neutral-600 dark:text-neutral-300",children:r.answer})})})]},r.question)})})}function Tx({count:e=5,className:t="h-4 w-4"}){return l.jsx("div",{className:"flex gap-0.5 text-amber-400",children:Array.from({length:e}).map((n,r)=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",className:t,children:l.jsx("path",{d:"M10 1.5l2.6 5.6 6.1.6-4.6 4.1 1.3 6-5.4-3.1-5.4 3.1 1.3-6-4.6-4.1 6.1-.6L10 1.5z"})},r))})}const iE=70;function oE({testimonials:e}){const t=p.useRef(null),n=p.useRef(null),r=p.useRef({pos:0,half:0,hovering:!1,dragging:!1,dragStartX:0,dragStartPos:0,lastTime:null,rafId:null}).current;p.useLayoutEffect(()=>{const i=n.current,o=window.matchMedia("(prefers-reduced-motion: reduce)").matches,a=()=>{i.style.transform=`translateX(${r.pos}px)`},u=g=>{if(r.half<=0)return g;for(;g>0;)g-=r.half;for(;g<=-r.half;)g+=r.half;return g},c=()=>{r.half=i.scrollWidth/2,r.pos===0?r.pos=-r.half:r.pos=u(r.pos),a()};c();const d=new ResizeObserver(c);d.observe(i);const f=g=>{r.lastTime===null&&(r.lastTime=g);const v=(g-r.lastTime)/1e3;r.lastTime=g,!r.dragging&&!r.hovering&&!o&&(r.pos=u(r.pos+iE*v),a()),r.rafId=requestAnimationFrame(f)};r.rafId=requestAnimationFrame(f);const h=t.current,y=()=>{r.hovering=!0},x=()=>{r.hovering=!1},w=g=>{r.dragging=!0,r.dragStartX=g.clientX,r.dragStartPos=r.pos,h.setPointerCapture(g.pointerId),h.classList.add("cursor-grabbing"),h.classList.remove("cursor-grab")},b=g=>{r.dragging&&(r.pos=u(r.dragStartPos+(g.clientX-r.dragStartX)),a())},m=g=>{r.dragging&&(r.dragging=!1,h.hasPointerCapture(g.pointerId)&&h.releasePointerCapture(g.pointerId),h.classList.remove("cursor-grabbing"),h.classList.add("cursor-grab"))};return h.addEventListener("pointerenter",y),h.addEventListener("pointerleave",x),h.addEventListener("pointerdown",w),h.addEventListener("pointermove",b),h.addEventListener("pointerup",m),h.addEventListener("pointercancel",m),()=>{cancelAnimationFrame(r.rafId),d.disconnect(),h.removeEventListener("pointerenter",y),h.removeEventListener("pointerleave",x),h.removeEventListener("pointerdown",w),h.removeEventListener("pointermove",b),h.removeEventListener("pointerup",m),h.removeEventListener("pointercancel",m)}},[e.length]);const s=[...e,...e];return l.jsx("div",{ref:t,className:"marquee-viewport cursor-grab touch-pan-y select-none overflow-hidden",children:l.jsx("div",{ref:n,className:"marquee-track flex w-max gap-5",children:s.map((i,o)=>l.jsx("div",{className:"w-64 shrink-0 sm:w-72 lg:w-80",children:l.jsxs("div",{className:"relative flex h-full flex-col overflow-hidden rounded-xl border border-neutral-200 bg-white p-6 shadow-sm transition-shadow duration-300 hover:shadow-lg dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsx("svg",{"aria-hidden":"true",viewBox:"0 0 32 24",className:"absolute -right-1 -top-1 h-16 w-16 text-brand-500/10 dark:text-brand-400/10",children:l.jsx("path",{fill:"currentColor",d:"M9.4 0C4.4 3.5 1 9.1 1 15.3 1 20.6 4.3 24 8.4 24c3.8 0 6.6-3 6.6-6.6 0-3.4-2.4-5.9-5.4-5.9-.6 0-1.4.1-1.6.2C8.5 8.5 11.6 4.6 14.6 2.6L9.4 0zm16.5 0c-4.8 3.5-8.3 9.1-8.3 15.3 0 5.3 3.3 8.6 7.5 8.6 3.7 0 6.6-3 6.6-6.6 0-3.4-2.5-5.9-5.4-5.9-.6 0-1.4.1-1.6.2.5-3.3 3.6-7.1 6.7-9.1L25.9 0z"})}),l.jsx(Tx,{className:"relative z-10 mb-3 h-4 w-4",count:i.rating||5}),l.jsxs("p",{className:"relative z-10 mb-4 line-clamp-6 flex-1 text-sm leading-relaxed text-neutral-600 dark:text-neutral-300",children:["„",i.text,'"']}),l.jsxs("div",{className:"relative z-10 mt-auto flex items-center gap-3",children:[i.photo?l.jsx("img",{src:i.photo,alt:"",referrerPolicy:"no-referrer",className:"h-9 w-9 shrink-0 rounded-full object-cover"}):l.jsx("span",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-full bg-brand-100 text-sm font-semibold text-brand-700 dark:bg-brand-900/40 dark:text-brand-300",children:i.name.charAt(0).toUpperCase()}),l.jsx("p",{className:"text-sm font-semibold text-neutral-900 dark:text-white",children:i.name})]})]})},`${i.name}-${o}`))})})}function Vm(e,t,n={x:0,y:0}){const r=Math.max(0,Math.min(100,e==null?n.x:Number(e)||0)),s=Math.max(0,Math.min(100,t==null?n.y:Number(t)||0));return{left:`${r}%`,top:`${s}%`,transform:`translate(-${r}%, -${s}%)`}}const aE="/assets/gallery-dash2-CEVCErVK.webp",Ex="/assets/gallery-amp-purple-CESAKuOf.webp",lE="/assets/gallery-speaker-CUXQZ49Q.webp",Nx="/assets/gallery-subs-COSd4seJ.webp",_x="/assets/gallery-dash-Cg-7v9qo.webp",uE="/assets/hero-trunk-Dp4_JHDh.webp",cE="/assets/gallery-rear-8cIXPC7T.webp",dE="/assets/hero-highlight-Co4f1Kj5.webp",fE="/assets/youtube-hintergrund-BqSbCrLQ.mp4",hE="/assets/youtube-hintergrund-mobil-BolxAIc0.mp4",Mi={left:"text-left",center:"text-center",right:"text-right"},mE={left:"",center:"mx-auto",right:"ml-auto"},pE={eyebrow_de:"",eyebrow_en:"",title_de:"",title_en:"",body_html_de:"",body_html_en:"",text_align:"center",text_align_x:50,text_align_y:50,button_label_de:"",button_label_en:"",button_url:"",font_family:null};function Fm({label:e,url:t,className:n,style:r}){const{hidden_areas:s}=Lt();return!e||!t||Cx(t,s)?null:t.startsWith("/")?l.jsx(W,{to:t,className:n,style:r,children:e}):l.jsx("a",{href:t,target:"_blank",rel:"noopener noreferrer",className:n,style:r,children:e})}const gE=[{src:Nx,width:900,height:600},{src:Ex,width:900,height:600},{src:lE,width:900,height:1200},{src:_x,width:900,height:814},{src:cE,width:900,height:1200},{src:uE,width:1920,height:1280}];function yE(){const{hero_image_path:e}=Lt(),t=e||aE,{t:n,language:r}=rt(),s=da(),i=!s("page.vehicles"),o=n("home.stats"),a=n("home.galleryAlts"),u=gE.map((I,U)=>({...I,alt:a[U]})),[c,d]=p.useState([]),[f,h]=p.useState({}),[y,x]=p.useState(!1),[w,b]=p.useState([]),m=I=>{const U=f[I]||pE,V=y&&{hero:n("home.heroTitle"),craft:n("home.craftTitle")}[I]||"",ae=y&&I==="hero"?`

${n("home.heroSubtitle")}

`:"";return{eyebrow:U[`eyebrow_${r}`]||"",title:U[`title_${r}`]||V,bodyHtml:U[`body_html_${r}`]||ae,align:U.text_align||"center",alignX:U.text_align_x,alignY:U.text_align_y,buttonLabel:U[`button_label_${r}`]||"",buttonUrl:U.button_url||"",fontFamily:U.font_family||void 0}},g=Be("home_sections.hero.eyebrow"),v=Be("home_sections.hero.title"),k=Be("home_sections.youtube.eyebrow"),S=Be("home_sections.youtube.title"),C=Be("home_sections.youtube.button_label"),j=Be("home_sections.craft.eyebrow"),P=Be("home_sections.craft.title"),M=Be("home_sections.advice.eyebrow"),E=Be("home_sections.advice.title"),O=Be("home_sections.insights.eyebrow"),K=Be("home_sections.insights.title"),H=Be("home_sections.more.eyebrow"),$=Be("home_sections.more.title"),se=Be("home_sections.more.button_label");p.useEffect(()=>{ce.get("/home-sections").then(h).catch(()=>x(!0))},[]),p.useEffect(()=>{ce.get("/partners").then(b).catch(()=>{})},[]);const[G,X]=p.useState(null),N=G?G.reviews.filter(I=>I.review_text).map(I=>({name:I.author_name,text:I.review_text,rating:I.rating,photo:I.profile_photo_url})):n("home.testimonials");p.useEffect(()=>{ce.get("/faqs").then(I=>{d(I.map(U=>({question:r==="de"?U.question_de:U.question_en,answer:r==="de"?U.answer_de:U.answer_en})))}).catch(()=>{})},[r]),p.useEffect(()=>{ce.get("/google-reviews").then(I=>{I.rating!=null&&I.reviews.some(U=>U.review_text)&&X(I)}).catch(()=>{})},[]),nr({title:n("home.metaTitle"),description:n("home.metaDescription"),path:"/"}),p.useEffect(()=>{if(c.length===0||s("home.faq"))return;const I=document.createElement("script");return I.type="application/ld+json",I.text=JSON.stringify({"@context":"https://schema.org","@type":"FAQPage",mainEntity:c.map(U=>({"@type":"Question",name:U.question,acceptedAnswer:{"@type":"Answer",text:U.answer}}))}),document.head.appendChild(I),()=>document.head.removeChild(I)},[c]),p.useEffect(()=>{var I;c.length>0&&window.location.hash==="#faq"&&((I=document.getElementById("faq"))==null||I.scrollIntoView())},[c]);const L=p.useRef(null);p.useEffect(()=>{var we,dt,Ln;const I=L.current;if(!I)return;const U=(we=window.matchMedia)==null?void 0:we.call(window,"(prefers-reduced-motion: reduce)").matches,V=(dt=navigator.connection)==null?void 0:dt.saveData;if(U||V)return;const Se=((Ln=window.matchMedia)==null?void 0:Ln.call(window,"(max-width: 767px), (pointer: coarse)").matches)?hE:fE,te=new IntersectionObserver(([Mx])=>{Mx.isIntersecting?(I.getAttribute("src")||(I.src=Se),I.play().catch(()=>{})):I.paused||I.pause()},{rootMargin:"300px 0px"});return te.observe(I),()=>te.disconnect()},[]);const F=p.useRef(null),{scrollYProgress:T}=sx({target:F,offset:["start start","end start"]}),A=Vj(),ie=an(T,[0,1],A?["0%","0%"]:["-6%","6%"]),z=an(T,[0,1],A?["0%","0%"]:["0%","60%"]),de=an(T,[0,.8],[1,0]),oe=an(T,[.5,1],[0,1]),re=an(oe,I=>I>.05?"auto":"none"),De=an(T,[.5,1],[16,0]);return l.jsxs("div",{children:[l.jsx(Kt.div,{style:{opacity:oe,pointerEvents:re,y:De},className:"fixed inset-x-0 bottom-0 z-20 border-t border-neutral-200 bg-white/95 px-4 py-3 shadow-[0_-8px_24px_rgba(0,0,0,0.08)] backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:px-6",children:l.jsxs("div",{className:"mx-auto flex max-w-6xl items-center justify-between gap-3",children:[l.jsx("p",{className:"hidden text-sm font-medium text-neutral-600 dark:text-neutral-300 sm:block",children:n("home.stickyCta")}),l.jsxs("div",{className:"flex w-full gap-3 sm:w-auto",children:[i&&l.jsx(W,{to:"/fahrzeuge",className:"flex-1 rounded-md bg-brand-500 px-5 py-2.5 text-center text-sm font-semibold text-white shadow-sm transition hover:-translate-y-0.5 hover:bg-brand-600 sm:flex-none",children:n("home.selectVehicle")}),l.jsx(W,{to:"/kontakt",className:"flex-1 rounded-md border border-neutral-300 px-5 py-2.5 text-center text-sm font-semibold text-neutral-700 transition hover:-translate-y-0.5 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800 sm:flex-none",children:n("home.getInTouch")})]})]})}),l.jsxs("section",{ref:F,className:"relative -mt-[89px] h-svh min-h-[560px] overflow-hidden sm:-mt-[97px]",children:[l.jsx(Kt.img,{style:{y:ie,scale:1.15},src:t,alt:n("home.heroImageAlt"),className:"absolute inset-0 h-full w-full object-cover"}),l.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-neutral-950 via-neutral-950/80 to-neutral-950/40"}),l.jsx(Kt.div,{style:{y:z,opacity:de},className:"absolute inset-0",children:l.jsx("div",{className:"absolute w-full max-w-2xl px-4 text-center sm:px-6",style:{...Vm(m("hero").alignX,m("hero").alignY,{x:50,y:50}),fontFamily:m("hero").fontFamily},children:l.jsxs(Kt.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.7,ease:"easeOut"},children:[m("hero").eyebrow&&l.jsx("p",{className:"mb-3 text-sm font-semibold uppercase tracking-wide text-brand-400",style:g,children:m("hero").eyebrow}),l.jsx("h1",{className:"text-3xl font-extrabold tracking-tight text-white sm:text-5xl",style:v,children:m("hero").title}),l.jsx("div",{className:"legal-content mx-auto mt-4 max-w-2xl text-base text-neutral-200 sm:text-lg",dangerouslySetInnerHTML:{__html:m("hero").bodyHtml}}),l.jsxs("div",{className:"mt-8 flex flex-wrap items-center justify-center gap-3",children:[i&&l.jsx(W,{to:"/fahrzeuge",className:"rounded-md bg-brand-500 px-6 py-3 text-sm font-semibold text-white shadow-sm transition hover:-translate-y-0.5 hover:bg-brand-600 hover:shadow-lg",children:n("home.selectVehicle")}),l.jsx(W,{to:"/kontakt",className:"rounded-md border border-white/30 bg-white/10 px-6 py-3 text-sm font-semibold text-white backdrop-blur transition hover:-translate-y-0.5 hover:bg-white/20",children:n("home.getInTouch")})]})]})})})]}),!s("home.stats")&&l.jsx("section",{className:"border-b border-neutral-200 bg-neutral-950 py-8 dark:border-neutral-800",children:l.jsx("div",{className:"mx-auto grid max-w-6xl grid-cols-2 gap-6 px-4 text-center sm:grid-cols-4 sm:px-6",children:o.map((I,U)=>l.jsxs(ze,{index:U,children:[l.jsx("p",{className:"text-2xl font-extrabold text-brand-400 sm:text-3xl",children:I.value}),l.jsx("p",{className:"text-sm text-neutral-400",children:I.label})]},I.label))})}),!s("home.partners")&&l.jsx("section",{className:"border-b border-neutral-200 py-8 dark:border-neutral-800",children:l.jsxs("div",{className:"mx-auto max-w-6xl px-4 sm:px-6",children:[l.jsx("p",{className:"mb-4 text-center text-xs font-semibold uppercase tracking-wide text-neutral-400",children:n("home.brandsHeading")}),l.jsx("div",{className:"flex flex-wrap items-center justify-center gap-x-8 gap-y-3",children:w.map((I,U)=>l.jsx(ze,{index:U,children:I.logo_path?l.jsx("img",{src:I.logo_path,alt:I.name,className:"h-8 max-w-[8rem] object-contain opacity-70 grayscale transition hover:opacity-100 hover:grayscale-0"}):l.jsx("span",{className:"text-lg font-bold text-neutral-400 dark:text-neutral-600",children:I.name})},I.id))})]})}),!s("home.youtube")&&l.jsxs("section",{className:"relative min-h-[70vh] overflow-hidden sm:min-h-[85vh]",children:[l.jsx("video",{ref:L,loop:!0,muted:!0,playsInline:!0,preload:"none",poster:_x,className:"absolute inset-0 h-full w-full object-cover"}),l.jsx("div",{className:"absolute inset-0 bg-black/55"}),l.jsx("div",{className:"absolute w-full max-w-3xl px-4 text-center sm:px-6",style:{...Vm(m("youtube").alignX,m("youtube").alignY,{x:50,y:50}),fontFamily:m("youtube").fontFamily},children:l.jsxs(ze,{children:[m("youtube").eyebrow&&l.jsx("p",{className:"mb-4 text-xs font-semibold uppercase tracking-[0.2em] text-neutral-200 sm:text-sm",style:k,children:m("youtube").eyebrow}),l.jsx("h2",{className:"text-3xl font-bold uppercase tracking-wide text-white sm:text-5xl",style:S,children:m("youtube").title}),l.jsx("div",{className:"legal-content mt-4 text-xs font-semibold uppercase tracking-wide text-neutral-200 sm:text-sm",dangerouslySetInnerHTML:{__html:m("youtube").bodyHtml}}),l.jsx(Fm,{label:m("youtube").buttonLabel,url:m("youtube").buttonUrl,className:"mt-8 inline-flex items-center justify-center rounded-full bg-white px-8 py-3 text-xs font-bold uppercase tracking-wide text-neutral-900 transition hover:-translate-y-0.5 hover:bg-neutral-100",style:C})]})})]}),!s("home.craft")&&l.jsx("section",{className:"grain-band border-y border-neutral-200 bg-neutral-50 py-16 dark:border-neutral-800 dark:bg-neutral-900/40",children:l.jsxs("div",{className:"mx-auto max-w-6xl space-y-16 overflow-hidden px-4 sm:px-6",children:[l.jsxs("div",{className:"grid items-center gap-8 md:grid-cols-2",children:[l.jsx(ze,{direction:"left",shine:!0,className:"rounded-xl shadow-lg",children:l.jsx("img",{src:Nx,alt:n("home.craftImageAlt"),width:900,height:600,className:"w-full rounded-xl object-cover",style:{maxHeight:380}})}),l.jsxs(ze,{direction:"right",index:1,className:Mi[m("craft").align],style:{fontFamily:m("craft").fontFamily},children:[m("craft").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:j,children:m("craft").eyebrow}),l.jsx("h2",{className:"mb-3 text-2xl font-bold text-neutral-900 dark:text-white",style:P,children:m("craft").title}),l.jsx("div",{className:"legal-content text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:m("craft").bodyHtml}})]})]}),l.jsxs("div",{className:"grid items-center gap-8 md:grid-cols-2",children:[l.jsxs(ze,{direction:"left",className:`order-2 md:order-1 ${Mi[m("advice").align]}`,style:{fontFamily:m("advice").fontFamily},children:[m("advice").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:M,children:m("advice").eyebrow}),l.jsx("h2",{className:"mb-3 text-2xl font-bold text-neutral-900 dark:text-white",style:E,children:m("advice").title}),l.jsx("div",{className:"legal-content text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:m("advice").bodyHtml}})]}),l.jsx(ze,{direction:"right",index:1,shine:!0,className:"order-1 md:order-2 rounded-xl shadow-lg",children:l.jsx("img",{src:Ex,alt:n("home.adviceImageAlt"),width:900,height:600,className:"w-full rounded-xl object-cover",style:{maxHeight:380}})})]})]})}),!s("home.insights")&&l.jsxs("section",{className:"mx-auto max-w-6xl px-4 py-16 sm:px-6",children:[l.jsxs(ze,{className:`mb-8 ${Mi[m("insights").align]}`,style:{fontFamily:m("insights").fontFamily},children:[m("insights").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:O,children:m("insights").eyebrow}),l.jsx("h2",{className:"text-2xl font-bold text-neutral-900 dark:text-white",style:K,children:m("insights").title}),l.jsx("div",{className:"legal-content mt-2 text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:m("insights").bodyHtml}})]}),l.jsx("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-3",children:u.map((I,U)=>l.jsx(ze,{index:U%3,shine:!0,className:"aspect-square overflow-hidden rounded-xl border border-neutral-200 dark:border-neutral-800",children:l.jsx("img",{src:I.src,alt:I.alt,width:I.width,height:I.height,loading:"lazy",className:"h-full w-full object-cover transition duration-300 hover:scale-105"})},I.src))})]}),!s("home.reviews")&&l.jsx("section",{className:"grain-band border-y border-neutral-200 bg-neutral-50 py-16 dark:border-neutral-800 dark:bg-neutral-900/40",children:l.jsxs("div",{className:"mx-auto max-w-6xl px-4 sm:px-6",children:[l.jsxs(ze,{className:"mb-10 text-center",children:[l.jsx("div",{className:"mb-2 flex items-center justify-center gap-2",children:l.jsx(Tx,{className:"h-6 w-6",count:G?Math.round(G.rating):5})}),l.jsx("h2",{className:"text-2xl font-bold text-neutral-900 dark:text-white",children:G?n("home.reviewsRatingDynamic")(G.rating,G.rating_count):n("home.reviewsRating")}),l.jsx("p",{className:"mt-1 text-neutral-600 dark:text-neutral-300",children:n("home.reviewsText")}),l.jsx("a",{href:"https://www.google.com/maps/search/?api=1&query=Hifi+Planet+Amorbach+Boxbrunner+Stra%C3%9Fe+20a",target:"_blank",rel:"noopener noreferrer",className:"mt-2 inline-block text-sm font-medium text-brand-600 hover:underline dark:text-brand-400",children:n("home.reviewsLink")})]}),l.jsx(ze,{children:l.jsx(oE,{testimonials:N})})]})}),!s("home.more")&&l.jsx("section",{className:"mx-auto max-w-6xl overflow-hidden px-4 py-16 sm:px-6",children:l.jsxs("div",{className:"grid items-center gap-10 md:grid-cols-2",children:[l.jsx(ze,{direction:"left",shine:!0,className:"overflow-hidden rounded-xl shadow-lg",children:l.jsx("img",{src:dE,alt:n("home.moreImageAlt"),width:1600,height:905,className:"h-full w-full object-cover",loading:"lazy"})}),l.jsxs(ze,{direction:"right",index:1,className:`rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900 ${Mi[m("more").align]}`,style:{fontFamily:m("more").fontFamily},children:[m("more").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:H,children:m("more").eyebrow}),l.jsx("h2",{className:"mb-3 text-2xl font-bold text-neutral-900 dark:text-white",style:$,children:m("more").title}),l.jsx("div",{className:`legal-content mb-8 max-w-2xl text-neutral-600 dark:text-neutral-300 ${mE[m("more").align]}`,dangerouslySetInnerHTML:{__html:m("more").bodyHtml}}),l.jsx(Fm,{label:m("more").buttonLabel,url:m("more").buttonUrl,className:"inline-block rounded-md border border-neutral-300 px-6 py-3 text-sm font-semibold text-neutral-700 transition hover:-translate-y-0.5 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",style:se})]})]})}),!s("home.faq")&&l.jsx("section",{id:"faq",className:"scroll-mt-20 border-t border-neutral-300 py-16 dark:border-neutral-700",children:l.jsxs("div",{className:"mx-auto max-w-3xl px-4 sm:px-6",children:[l.jsx(ze,{className:"mb-8 text-center",children:l.jsx("h2",{className:"text-2xl font-bold text-neutral-900 dark:text-white",children:n("home.faqHeading")})}),l.jsx(ze,{index:1,children:l.jsx(sE,{items:c})})]})})]})}function ma(e,t){return e?e.code==="rate_limited"||e.status===429?t("errors.rateLimited"):e.code==="invalid_input"||e.status===422?t("errors.invalidInput"):e.status===404?t("errors.notFound"):e.status===503?t("errors.maintenance"):e.status>=500?t("errors.server"):e.status?t("errors.generic"):t("errors.network"):""}function xE(){const[e,t]=p.useState(null),[n,r]=p.useState(null),s=fa(),{t:i}=rt(),o=Cd(),{vehicle_tile_width:a,vehicle_tile_height:u}=Lt(),c={width:`${a}px`,height:`${u}px`};return nr({title:i("vehicleSelect.metaTitle"),description:i("vehicleSelect.metaDescription"),path:"/fahrzeuge"}),p.useEffect(()=>{s.vehicles.enabled&&!s.bypass||ce.get("/brands").then(t).catch(d=>r(d))},[s.vehicles.enabled,s.bypass]),s.vehicles.enabled&&!s.bypass?l.jsx(oi,{message:s.vehicles.message}):l.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[s.vehicles.enabled&&s.bypass&&l.jsx(ai,{inline:!0}),l.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:i("vehicleSelect.title")}),l.jsx("p",{className:"mb-8 text-neutral-600 dark:text-neutral-300",children:i("vehicleSelect.intro")}),n&&l.jsx("p",{className:"text-red-600",children:typeof n=="string"?n:ma(n,i)}),e===null&&!n&&l.jsx("div",{className:"flex flex-wrap gap-4","aria-busy":"true","aria-label":i("vehicleSelect.loading"),children:Array.from({length:6},(d,f)=>l.jsx("div",{style:c,className:"shrink-0 animate-pulse rounded-xl bg-neutral-200 dark:bg-neutral-800"},f))}),(e==null?void 0:e.length)===0&&!n&&l.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:i("vehicleSelect.empty")}),l.jsx("div",{className:"flex flex-wrap gap-4",children:(e||[]).map(d=>d.image_path?l.jsxs(W,{to:`/fahrzeuge/${d.slug}`,style:c,className:"group relative block shrink-0 overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[l.jsx("img",{src:d.image_path,alt:"",loading:"lazy",decoding:"async",width:a,height:u,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}),l.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),l.jsx("span",{className:"absolute inset-x-0 bottom-0 p-4 text-center text-lg font-extrabold text-white",style:Jn(o,`brands.${d.id}.name`),children:d.name})]},d.id):l.jsx(W,{to:`/fahrzeuge/${d.slug}`,style:c,className:"flex shrink-0 flex-col items-center justify-center gap-3 rounded-xl border border-neutral-200 bg-white px-6 text-center font-semibold text-neutral-800 shadow-sm transition hover:-translate-y-0.5 hover:border-brand-500 hover:shadow-md dark:border-neutral-800 dark:bg-neutral-900 dark:text-neutral-100",children:l.jsx("span",{style:Jn(o,`brands.${d.id}.name`),children:d.name})},d.id))})]})}function Ed(){const{t:e}=rt(),{phone:t}=Lt(),n=da();return nr({title:e("notFound.metaTitle"),noindex:!0}),l.jsxs("div",{className:"mx-auto max-w-2xl px-4 py-20 text-center sm:px-6",children:[l.jsx("p",{className:"text-sm font-semibold uppercase tracking-[4px] text-brand-500",children:"404"}),l.jsx("h1",{className:"mt-3 text-3xl font-bold text-neutral-900 dark:text-white sm:text-4xl",children:e("notFound.title")}),l.jsx("p",{className:"mx-auto mt-4 max-w-md text-neutral-600 dark:text-neutral-300",children:e("notFound.text")}),l.jsxs("div",{className:"mt-10 flex flex-wrap justify-center gap-3",children:[!n("page.vehicles")&&l.jsxs(W,{to:"/fahrzeuge",className:"inline-flex items-center gap-2 rounded-md bg-brand-500 px-5 py-3 text-sm font-semibold text-white shadow-sm hover:bg-brand-600",children:[l.jsx(Oo,{className:"h-4 w-4"}),e("notFound.toVehicles")]}),l.jsxs(W,{to:"/kontakt",className:"inline-flex items-center gap-2 rounded-md border border-neutral-300 px-5 py-3 text-sm font-semibold text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:[l.jsx(zu,{className:"h-4 w-4"}),e("notFound.toContact")]}),t&&l.jsxs("a",{href:Sd(t),className:"inline-flex items-center gap-2 rounded-md border border-neutral-300 px-5 py-3 text-sm font-semibold text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:[l.jsx(Or,{className:"h-4 w-4"}),t]})]}),l.jsx(W,{to:"/",className:"mt-8 inline-block text-sm text-neutral-500 underline hover:text-brand-500",children:e("notFound.toHome")})]})}function vE(){const{brandSlug:e}=Bc(),[t,n]=p.useState(null),[r,s]=p.useState(null),i=fa(),{t:o}=rt(),a=Cd(),u=Be(t?`brands.${t.brand.id}.name`:""),{vehicle_tile_width:c,vehicle_tile_height:d}=Lt(),f={width:`${c}px`,height:`${d}px`};return p.useEffect(()=>{i.vehicles.enabled&&!i.bypass||ce.get(`/brands/${e}/models`).then(n).catch(h=>s(h))},[e,i.vehicles.enabled,i.bypass]),nr({title:t?`${t.brand.name} ${o("brandPage.titleSuffix")}`:o("brandPage.metaTitleFallback"),description:t?o("brandPage.metaDescription")(t.brand.name):void 0,path:`/fahrzeuge/${e}`}),i.vehicles.enabled&&!i.bypass?l.jsx(oi,{message:i.vehicles.message}):r?r.status===404?l.jsx(Ed,{}):l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:ma(r,o)}):t?l.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[i.vehicles.enabled&&i.bypass&&l.jsx(ai,{inline:!0}),l.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[l.jsx(W,{to:"/fahrzeuge",className:"hover:text-brand-500",children:o("brandPage.breadcrumbVehicles")})," / ",l.jsx("span",{style:u,children:t.brand.name})]}),l.jsxs("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:[l.jsx("span",{style:u,children:t.brand.name})," – ",o("brandPage.titleSuffix")]}),t.models.length===0&&l.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:o("brandPage.empty")}),l.jsx("div",{className:"flex flex-wrap gap-4",children:t.models.map(h=>h.image_path?l.jsxs(W,{to:`/fahrzeuge/${e}/${h.slug}`,style:f,className:"group relative block shrink-0 overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[l.jsx("img",{src:h.image_path,alt:"",loading:"lazy",decoding:"async",width:c,height:d,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}),l.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),l.jsx("span",{className:"absolute inset-x-0 bottom-0 p-4 text-center text-lg font-extrabold text-white",style:Jn(a,`car_models.${h.id}.name`),children:h.name})]},h.id):l.jsx(W,{to:`/fahrzeuge/${e}/${h.slug}`,style:f,className:"flex shrink-0 flex-col items-center justify-center gap-3 rounded-xl border border-neutral-200 bg-white px-6 text-center font-semibold text-neutral-800 shadow-sm transition hover:-translate-y-0.5 hover:border-brand-500 hover:shadow-md dark:border-neutral-800 dark:bg-neutral-900 dark:text-neutral-100",children:l.jsx("span",{style:Jn(a,`car_models.${h.id}.name`),children:h.name})},h.id))})]}):l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:o("brandPage.loading")})}function wE({text:e}){return e?e.split(/(\*\*[^*]+\*\*)/g).map((n,r)=>{const s=n.match(/^\*\*([^*]+)\*\*$/);return s?l.jsx("strong",{children:s[1]},r):l.jsx("span",{children:n},r)}):null}const Om="data:image/webp;base64,UklGRmoNAABXRUJQVlA4IF4NAAAQjACdASrgAVYDPlEok0ajoqGhIRK4IHAKCWlu/F+5xDCoDux8VXNtc99B5Uf715Q+k/+V6E/yD7bfvf7tYI7QKys1Pu/n/K9wD+L/0L/aeqHflfZf937AH81/p//N/yXr9f9f+M/yf7c+4D6R/7n+O+BL9d+rb+0f//9yX9VQU+fHDhw4cN7KTkCBAgQIECBAgQIEB8GtgzU5WrVq1atWrVq1atTTWWxGRvDLM5r169evXr169evVcNgPhleRXp06dOnTp06dOnTpUIn65+OKaJVsmzZs2bNmzZs2bNmSyYC6ipEunTp06dOnTp06dOlydZVuN901q1atWrVq1atWrVXZqLYS16JYyeHDhw4cOHDhw4cN4wtQeDaQLgECBAgQIECBAgQIDddB6sEmQB2atWrVq1atWrVq1aq1iYS5JU9iBlzXr169evXr169evXeEPp+8N6OklatWrVq1atWrVq1V3IfqDdZ8CK1AgQIECBAgQIECBBQFoI3bXHSzdGb8+OHDhw4cOHDhw4ZwLNj/Gx48ePHjx48ePHjx5HaZ5q8hFQPLVq1atWrVq1atWrVWlrSSS1atWrVq1atWrVq1VouJ4vs1atWrVq1atWrVqzMNN6naRaj4OHDhw4cOHDhwzggYy8goXr169evXr169evXbAmy3nWg79+/fv379+/fv377Aw+GV3JG24BIkSJEiRIkSJEiRH091sORb3KZK2rVq1atWrVq1atWZgOgxn2g3CECBAgQIECBAgQHwEh4tRYq5WHRSJEiRIkSJEiRIkRmQ4gXd9q0Xa9evXr169evXr169SUP3aSDmqBOfHDhw4cOHDhw4cN/rYXzoW6jx48ePHjx48ePHjwyNgV/F/hRIkSJEiRIkSJEiRGcgeccx2x48ePHjx48ePHjx5+h2DL7y1q1atWrVq1atWrVqrLjxn1+UevXr169evXr169epWz/ixb7G7Fx48ePHjx48ePHjx64Dpo0+TFzjw4cOHDhw4cOHDhwr64/FOVqj1ftlBYsWLFixYsWLFixsB93m6MKtrfi/YePHjx48ePHjx48eGCFP4MdBX+BXbQiRIkSJEiRIkSJEiA+X4/Ne4l0FixYsWLFixYsWLTKZjxkHLs7TTrVq1atWrVq1atWrSGY83Cktx0PPjhw4cOHDhw4cN/7Xmd/H4DxEePHjx48ePHjx48ct7KWpas7p5jy5cuXLly5cuXLlyM+h2/gRIkSJEiRIkSJEiRAPRMs9EnbFixYsWLFixYsWLBwJstxClHwcOHDhw4cOHDhw3+o6GvCGxY8ePHjx48ePHjx45aAayr3BCnnxw4cOHDhw4cOG/2HuJWxIvK1JLZs2bNmzZs2bNmyAMNnZLnTo6dOnTp06dOnTp06Vd0rFPQfnwwCPHjx48ePHjx48eOU7jRhCFUn5bFixYsWLFixYsWKZRr/1LzwcOHDhw4cOHDhw4ZshIGgexQoECBAgQIECBAgQH+hD+jvXr169eu0AAP7/2BA2pStbx3f0LK6/mZcFuZpv73FLTm7GUv07j8lFLoOGX1EwKUHfPc4FImBkAvjxF1E2TgBogJKpQ2lbMv5bOqPckB4PELJo9ZXlMwGup4PkMOtTZPmrbNoaCJqn0H4Bx7A0xA439P5hkMGBnAEfInQIN5UeUIDb3y6tLej2gR8HhJ5XmTsxvmM15ltL5ZwdGmoNeW8NevUVUKqJ8mNngu7ocCsyGYaeYOGGZBBt6rj6bPVKVbxvb8onw6mljAaaxGTz0W+aNPv06kK3qhDe6/uHi8kg2qvjF3njhRMyOJKZzg12h4qOtVgTuKPAMRWYDkgwiRs9iYqcumonNNXvXk3FAk2LO5XnyjtD5sHSUO3pIrztpBvqq+UJzKeIwGBlPwA2NP46tOJxLzbrKeH4SQjt2HAsbrVcQ/b/TgKZGPwaqfGDN+OjqJK3Z9dyCkGGfGKeG1w9+HSZTm/qh052lQEJAcdUX6vm/+sDBxtrfl4Sg8iMcVnDsfTKJpsTYF/vzJ1oQ6/VPyIX1HpDwnPXsptu9rKDFazlkwc3ofi8uKJmycgPiG9xOLlzn4Af8Dm+LcjJUMAtA7XeZPLlW1bwogbRthU8oA4LcURuku6eXDJ1eb1IKUU7k/UK0cBeK+R5YVcmrOnZIyHzcIaClYnrIwerP535fHv4VXjURTO6/85BvSeTNWvQGqkW5v1hG6AEMrxBryfat3kmr+SNEz5wC2f54z1O7C2KsRpt3maISh9PhMg7jDIxmVe07eHtkLtz6v3yQUJQV95yazDYpH5JfpuYSb8dtmB1cKjeoDTPvik9dCA1UFCTZBfojpIOwXdwAR7JEdZkEi/24hMNKJJlB6udZZKqNJB1hNl24Z++z6lAGSAuRgSwDZGdbqxs+0iL6wmRHilqPOiYB6hQiPZ7cfpMZxesqRwyhcf1O29w4ORG/7BlerR8hYvY4B1XsPYbDORvPk6FHIDXwTXGpuDIta7G4F6RNDdOvCFkAl53GZo5h/p2QkWUry5YuyegnPlKjT3He6ewYypA9YOvMhaqip7kr9sF4TU2bX9foKZ+FFZNzhyySS+13+g4BdJo9YF3bw5b6eSxUfTWiDLNh50VjuqRQWHUEkiA8zJqnqkKCwuDy6iY2oF20FJQlGIPpCDKPBzdXSb/n9NDltaoUlbam7cDAU7CwNdaWFXTABRk0S0e49iF4tO106Uwul7DGYpq0Eu71TnKUjCtEBc83QH8skvRzHniEne3AtJLYRH0cMNSSzeCJ1g+Nfc8RaZkhLhCaZGZdYe5j0LGmQnVFt2iapZvGBi7Sw0X56zdziC9Foq0OPsqKFetZdICc2eUV5Vu1+nvisSzn8wlSDUt3OmRkt/gJxfJQfWxcu5HZ26qqNpA4ablWrX4E9DEmvXzpFGYCnYJMheN2BlWwBVLh1cyQ8INngXaoB8I5Pj9oYyuz/W+jvJQ6G074luX9D3pLkuc88D0Hae3ZqXrRYRzGF1vD8pHsk9Co8B6rpE/4GEwW/zsCtnjz5G8m4KFwf2qW1k0HkNv7Nlg38bcz6TdTzuw/jega5XZQQhflLu4I6l+s90BHFIR+JEXTBBqJwT+IgTnpHNc+h5Ek74HiKqXuGUNGIKIozHkiFxMlnrsklrpweBzYY6ype9CzepAuQF63xC/eIJw1pMZEC1pPgq/r+1gWx5M6g8fpu2O12sb6pLeqT+G4mK3yHMZTojfp1xwQedRmwZnWQ8SCh4XV2a/+3OTz4D4pmmumyBV7V2VW3he8y6usinSjfYPxLyTng27fgw6jQhHl2mVhxBBjiwr5ljvJV7L+MJYDiZjGWfBCsTmehk6rbNt7ahTJpHu4B9ctRqiZXjx0zGpTF91OKifmy4nTq31p1XaIsZAHCWvItXKeke06KKKRTIm6mCT9yBJVwG1sqQhjrkP77q0/JGYgOwgdCQCstsAZQ0FlOrGYXYTIQK/krLyCAZjg8vP/Ers/KVN8F88OsyU5/T1e5ba8A2F63qgwhtkWoVIEZErOVL8sM/DtpWTlcBNsvVOFl4tT+Sk6a2ScCptFL5F6cZXTIw8JmgoCbyqB6xyU+uPP5y09s5T8MDC7Em7NpxCjgD39eed40gHQrBm6CtAbS9JOCVPkPxbpcGDj/LoAGbnyYzMpOmTi28LJ9FTIqyGuAI0jxY/QpNelOOEvNK3io1HeYkK3AprImDk99tlUjgt9bc3ejCOFDXt9LqGHjFssGrhVHyJBmWjwHQipcIMHxF2jfP5jfAGuHtJRRncHIFgLWmJ1XmzJ0LLqWCJShdJSJLc7L6YeVcgKfzOZCwhtzJ7VeI3uBhPXQNOqCf5tlQ32HApAMvCIiBwhYrpfFo/kvjfTMB/NJ0w2Lk8GAFfFQY+U6uX1oB0hztGmA5HggJTwgLo8exG64m3Xu4fg2g4MmQol7z6xNwwubABnpoS3Og85giFkaarUP2ovQyixFpXki8Xf5a5NwjUGCPbx+LD3WKJiBtkiHsYMMV/VAZVNvdg/Ph/V4ZYOr+hw7g9mOJXi+oVZxG9pqJC9w8nRkegsnQ2lpRHn22lTsIa9aOkR0X8zp/IajQxUzv057a3WptBst0EZbZtfmWp6h2K0sDQS9oQT1PqOkGDJlz6ZHZzDMShDTcwJfIZMdnjpeHdPoYoqlcn3M8daRuMeTSP3mabP1/pdQrs6Wl7ToKog2Au/gv46pUMgVcKmdWNJdDF8RplMMXJpU2tZMdkTWq4ofSypsCfuWfeHOpFQGJdFF6OoH2pDJXvkqpj1a832g3uYtVQg1TGyqYqI7UBZQy4NEZbdj6O/s6MNEnfujUDQ8QZj7rSE2RI77egKDWzM708AsvlMFoeX4CVP09rMzXNP2aOZwY7zOBTvBgEEqCWlXAFlY8pW0zIm16gqSPiwRUgH41i1PuJx382C0zTWGT243ZhLnyOIlreUrMQAfwR/oYt+ljnDFKqa5PEczDPa+u/vWmR6UM+Q/lLFiIlgBJTfaekWoeLpPd9FPN4gIHzK1ZS8kDHyq3lh/e6FQ84a4Zg6JlfQC/qhAAAAA==",kE="/assets/base-BKOm0Bib.webp",bE="/assets/clear-DZZMSrMX.webp",SE="/assets/drive-BE2W1yna.webp",PE="/assets/prime-BTVNe2Gb.webp",jE="/assets/elite_r-BRvz_pyr.webp",CE="/assets/apex-CFy2qup8.webp",TE="/assets/statement-pTO-wTPx.webp",EE="/assets/limitless-DDs0S_PU.webp";function Pn(e,t,n){if(!e)return"";if(n==="en"){const r=e[`${t}_en`];if(r)return r}return e[t]}const NE=(e,t,n)=>{t/=100,n/=100;const r=o=>(o+e/30)%12,s=t*Math.min(n,1-n),i=o=>n-s*Math.max(-1,Math.min(r(o)-3,Math.min(9-r(o),1)));return[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)]},cl=(e,t,n)=>`rgb(${NE(e,t,n).join(", ")})`,zm=e=>e.map(([t,n,r,s,i,o])=>({bgTop:cl(t,n,r),border:cl(t,n,r+8),accent:cl(s,i,o),img:null})),Bm={graphite:[{accent:"#b6b6b6",border:"#2a2a2a",bgTop:"#1c1c1c",img:kE},{accent:"#d3d3d3",border:"#2e2e2e",bgTop:"#212121",img:bE},{accent:"#8fb8bd",border:"#26383b",bgTop:"#16282b",img:SE},{accent:"#6fbf73",border:"#1f3a24",bgTop:"#122916",img:PE},{accent:"#63d34f",border:"#204a1c",bgTop:"#123312",img:jE},{accent:"#8bea3c",border:"#2b5518",bgTop:"#173a0f",img:CE},{accent:"#d9a83c",border:"#4a3a16",bgTop:"#33270d",img:TE},{accent:"#f2c14e",border:"#5a4718",bgTop:"#3d2f0c",img:EE}],"deep-blue":zm([[215,18,11,210,15,60],[212,25,11,208,32,60],[210,38,12,206,46,60],[212,46,12,205,56,61],[214,52,12,205,63,62],[216,58,12,205,68,63],[220,62,12,212,73,65],[226,66,12,216,78,68]]),"warm-bronze":zm([[30,15,11,34,22,60],[34,32,11,34,46,60],[32,46,12,30,58,60],[26,52,12,24,65,60],[20,55,12,18,68,60],[14,55,12,12,68,61],[8,52,12,6,64,62],[2,50,12,358,60,63]])},_E="#f2f2f2",Hm="#8a8a8a",ME="#c4c4c4",$m=5,LE=3,AE={recommended:{Icon:qC,className:"bg-brand-500 text-white"},popular:{Icon:PC,className:"bg-amber-400 text-neutral-950"},tip:{Icon:EC,className:"bg-sky-500 text-white"},coming_soon:{Icon:ux,className:"bg-white text-neutral-900"},custom:{Icon:null,className:"bg-brand-500 text-white"}};function DE({pkg:e,tier:t,tierT:n,layout:r,bullets:s,formatPrice:i,contactUrl:o,priceNote:a,t:u}){const[c,d]=p.useState(!1),[f,h]=p.useState(!1),y=p.useRef(null),x=s.length-$m,w=c?s:s.slice(0,$m);p.useLayoutEffect(()=>{const P=y.current;if(!P||c){h(!1);return}const M=()=>h([...P.querySelectorAll("[data-clamp]")].some(O=>O.scrollHeight>O.clientHeight+1));M();const E=new ResizeObserver(M);return E.observe(P),()=>E.disconnect()},[c,s.length,e.description]);const b=Cd(),m=Jn(b,`packages.${e.id}.description`),g=Jn(b,`packages.${e.id}.price_text`),{package_card_height:v}=Lt(),k=AE[e.badge],S=r!=="grid",C=e.badge==="custom"?e.badge_text:e.badge&&u(`modelPage.badges.${e.badge}`),j=t.img?null:{backgroundColor:t.accent,WebkitMaskImage:`url(${Om})`,maskImage:`url(${Om})`,maskMode:"luminance",WebkitMaskSize:"cover",maskSize:"cover",WebkitMaskPosition:"center",maskPosition:"center",WebkitMaskRepeat:"no-repeat",maskRepeat:"no-repeat"};return l.jsxs("div",{style:{borderColor:t.border,background:`linear-gradient(180deg, ${t.bgTop} 0%, #0b0b0b 55%, #080808 100%)`,...S?{gridRow:"span 4",gridTemplateRows:"subgrid",rowGap:0}:{minHeight:`${v}px`}},className:r==="strip"?"relative grid snap-start overflow-hidden rounded-[18px] border shadow-xl shadow-neutral-900/20 dark:shadow-black/40":r==="coverflow"?"relative grid snap-center overflow-hidden rounded-[18px] border shadow-xl shadow-neutral-900/20 will-change-transform dark:shadow-black/40":"relative flex flex-col overflow-hidden rounded-[18px] border shadow-xl shadow-neutral-900/20 dark:shadow-black/40",children:[t.img?l.jsx("img",{src:t.img,alt:"","aria-hidden":"true",className:"pointer-events-none absolute inset-0 h-full w-full object-cover"}):l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"pointer-events-none absolute inset-0",style:{...j,opacity:.2+n*.45,filter:"blur(18px)"},"aria-hidden":"true"}),l.jsx("div",{className:"pointer-events-none absolute inset-0",style:{...j,opacity:.55+n*.45},"aria-hidden":"true"})]}),k&&C&&l.jsxs("span",{className:`absolute top-2 left-1/2 z-10 flex max-w-[calc(100%-16px)] -translate-x-1/2 items-center gap-1 whitespace-nowrap rounded-full px-3 py-1 text-xs font-bold shadow ${k.className}`,children:[k.Icon&&l.jsx(k.Icon,{className:"h-3.5 w-3.5 shrink-0","aria-hidden":"true"}),l.jsx("span",{className:"truncate",children:C})]}),l.jsxs("div",{className:"relative z-10 text-center",style:{padding:"34px 20px 0",gridRow:1},children:[l.jsx("div",{style:{fontFamily:"'Barlow Condensed', sans-serif",fontSize:"30px",letterSpacing:"3px",fontWeight:600,color:t.accent,textTransform:"uppercase",lineHeight:1.1},children:e.name}),l.jsx("div",{style:{width:"44px",height:"2px",margin:"14px auto 0",background:`linear-gradient(90deg, rgba(255,255,255,0) 0%, ${t.accent} 50%, rgba(255,255,255,0) 100%)`}})]}),s.length>0&&l.jsxs("div",{className:"relative z-10",style:{gridRow:2,padding:"18px 20px 14px",background:c?"linear-gradient(180deg, rgba(8,8,8,0.7) 0%, rgba(8,8,8,0.62) 94%, rgba(8,8,8,0) 100%)":"linear-gradient(180deg, rgba(8,8,8,0.55) 0%, rgba(8,8,8,0.48) 92%, rgba(8,8,8,0) 100%)"},children:[l.jsx("ul",{ref:y,className:"space-y-1.5 text-left",children:w.map((P,M)=>l.jsxs("li",{className:"flex items-start gap-2",style:{fontSize:"13px",color:ME,...P.fromDescription?m:null},children:[l.jsx(aC,{className:"mt-0.5 h-3.5 w-3.5 shrink-0",style:{color:t.accent}}),l.jsx("span",{"data-clamp":!0,className:"leading-snug",style:c?void 0:{display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:LE,overflow:"hidden"},children:P.fromDescription?l.jsx(wE,{text:P.text}):P.text})]},M))}),(c||x>0||f)&&l.jsxs("button",{type:"button",onClick:()=>d(P=>!P),className:"mt-2.5 flex items-center gap-1 hover:opacity-80",style:{fontSize:"13px",color:t.accent},children:[c?u("modelPage.lessBullets"):x>0?u("modelPage.moreBullets")(x):u("modelPage.showMore"),c?l.jsx(pC,{className:"h-3.5 w-3.5"}):l.jsx(uC,{className:"h-3.5 w-3.5"})]})]}),l.jsx("div",{className:"relative z-10 flex-1",style:{gridRow:3}}),l.jsx("div",{className:"relative z-10",style:{gridRow:4,padding:"20px 20px 28px",background:"linear-gradient(180deg, rgba(8,8,8,0) 0%, rgba(8,8,8,0.85) 45%, rgba(8,8,8,0.95) 100%)"},children:l.jsxs("div",{className:"text-center",children:[!e.price_text&&l.jsx("div",{style:{fontSize:"13px",color:Hm},children:u("modelPage.totalPrice")}),l.jsx("div",{style:{marginTop:"4px",fontFamily:"'Barlow Condensed', sans-serif",fontSize:"30px",fontWeight:600,letterSpacing:"1px",color:_E,...e.price_text?g:null},children:e.price_text||i(e.total_price)}),!e.price_text&&a&&l.jsx("div",{style:{marginTop:"2px",fontSize:"11px",color:Hm},children:a}),l.jsx(W,{to:o(e),onClick:()=>Sn("select_package",{package_name:e.name,value:Number(e.total_price)||void 0,currency:"EUR"}),className:"mt-4 inline-block rounded-md bg-brand-500 px-4 py-2 text-center text-sm font-semibold text-white shadow-lg shadow-brand-500/30 hover:bg-brand-400",children:u("modelPage.requestContact")}),e.video_url&&l.jsx("div",{className:"mt-3",children:l.jsxs("a",{href:e.video_url,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 rounded-full border border-white/15 bg-white/5 px-3 py-1 text-xs font-semibold text-white transition hover:bg-white/15",children:[l.jsx(yC,{className:"h-4 w-4 text-red-500","aria-hidden":"true"}),u("modelPage.videoLink")]})})]})})]})}function RE(){const{brandSlug:e,modelSlug:t}=Bc(),[n,r]=p.useState(null),[s,i]=p.useState(null),o=fa(),{t:a,language:u}=rt(),{package_card_theme:c,package_card_layout:d,package_wheel_hint_interval:f,package_card_width:h,package_card_height:y,phone:x,whatsapp:w,price_note:b,price_note_en:m}=Lt(),g=u==="en"&&m||b,v=Bm[c]||Bm.graphite,k=["grid","strip","coverflow"].includes(d)?d:"strip",S=Math.max(2,Number(f)||8)*1e3,C=p.useRef(null),j=p.useRef(null),P=p.useRef(null),[M,E]=p.useState(!1),O=T=>new Intl.NumberFormat(u==="de"?"de-DE":"en-US",{style:"currency",currency:"EUR"}).format(T);p.useEffect(()=>{o.vehicles.enabled&&!o.bypass||ce.get(`/models/${e}/${t}/packages`).then(r).catch(T=>i(T))},[e,t,o.vehicles.enabled,o.bypass]),p.useEffect(()=>{const T=C.current;if(k!=="coverflow"||!T)return;let A=0;const ie=()=>{A=0;const oe=T.scrollLeft+T.clientWidth/2;for(const re of T.children){const De=re.offsetLeft+re.offsetWidth/2,I=Math.max(-1,Math.min(1,(De-oe)/(re.offsetWidth*1.4))),U=Math.abs(I);re.style.transform=`rotateY(${(-I*35).toFixed(2)}deg) scale(${(1-U*.13).toFixed(3)}) translateZ(${(-U*60).toFixed(1)}px)`,re.style.zIndex=String(100-Math.round(U*50))}},z=()=>{A||(A=requestAnimationFrame(ie))};ie(),T.addEventListener("scroll",z,{passive:!0});const de=new ResizeObserver(z);return de.observe(T),()=>{T.removeEventListener("scroll",z),de.disconnect(),cancelAnimationFrame(A)}},[k,n]),p.useEffect(()=>{const T=C.current;if(k==="grid"||!T)return;const A=window.matchMedia("(pointer: coarse)").matches;if(window.matchMedia("(prefers-reduced-motion: reduce)").matches)return;let z=[],de=0;const oe=()=>{const De=Math.min(T.clientWidth*.4,160);z.push(setTimeout(()=>T.scrollTo({left:De,behavior:"smooth"}),500)),z.push(setTimeout(()=>T.scrollTo({left:0,behavior:"smooth"}),1250)),A||(z.push(setTimeout(()=>E(!0),450)),z.push(setTimeout(()=>E(!1),1700)))},re=new IntersectionObserver(([De])=>{De.isIntersecting&&(re.disconnect(),oe(),de=setInterval(()=>{T.scrollLeft<=1&&oe()},S))},{threshold:.35});return re.observe(T),()=>{re.disconnect(),clearInterval(de),z.forEach(clearTimeout)}},[k,n,S]),p.useEffect(()=>{const T=C.current;if(k==="grid"||!T)return;let A=0,ie=0,z=!1,de=0,oe=0;const re=()=>[...T.children].map(V=>V.offsetLeft+V.offsetWidth/2),De=(V,ae)=>{let Se=0,te=1/0;return V.forEach((we,dt)=>{const Ln=Math.abs(we-ae);Ln{z=!1;const V=re();if(!V.length)return;const ae=T.scrollLeft+T.clientWidth/2,Se=De(V,ae);let te=Se;Se===de&&Math.abs(oe)>4&&(te=oe>0?Math.min(de+1,V.length-1):Math.max(de-1,0));const we=T.scrollWidth-T.clientWidth,dt=Math.max(0,Math.min(V[te]-T.clientWidth/2,we));T.scrollTo({left:dt,behavior:"smooth"}),clearTimeout(ie),ie=setTimeout(()=>{T.style.scrollSnapType=""},450)},U=V=>{if(Math.abs(V.deltaX)>Math.abs(V.deltaY))return;const ae=T.scrollWidth-T.clientWidth;if(ae<=1)return;const Se=T.scrollLeft<=1,te=T.scrollLeft>=ae-1;V.deltaY<0&&Se||V.deltaY>0&&te||(V.preventDefault(),z||(z=!0,oe=0,de=De(re(),T.scrollLeft+T.clientWidth/2)),oe+=V.deltaY,T.style.scrollSnapType="none",T.scrollLeft+=V.deltaY,clearTimeout(A),A=setTimeout(I,150))};return T.addEventListener("wheel",U,{passive:!1}),()=>{T.removeEventListener("wheel",U),clearTimeout(A),clearTimeout(ie)}},[k,n]),p.useEffect(()=>{const T=C.current,A=j.current,ie=P.current;if(k==="grid"||!T||!A||!ie)return;let z=0;const de=()=>{z=0;const te=T.scrollWidth-T.clientWidth;if(te<=1){A.style.opacity="0",A.style.pointerEvents="none";return}A.style.opacity="1",A.style.pointerEvents="auto";const we=A.clientWidth,dt=Math.max(32,T.clientWidth/T.scrollWidth*we);ie.style.width=`${dt}px`,ie.style.transform=`translateX(${(T.scrollLeft/te*(we-dt)).toFixed(1)}px)`},oe=()=>{z||(z=requestAnimationFrame(de))};de(),T.addEventListener("scroll",oe,{passive:!0});const re=new ResizeObserver(oe);re.observe(T);let De=!1,I=0;const U=te=>{const we=A.getBoundingClientRect(),dt=ie.clientWidth,Ln=Math.min(Math.max(te-we.left-I,0),we.width-dt);T.scrollLeft=Ln/(we.width-dt)*(T.scrollWidth-T.clientWidth)},V=te=>{De=!0,A.setPointerCapture(te.pointerId),T.style.scrollSnapType="none";const we=ie.getBoundingClientRect();I=te.clientX>=we.left&&te.clientX<=we.right?te.clientX-we.left:ie.clientWidth/2,te.clientX>=we.left&&te.clientX<=we.right||U(te.clientX)},ae=te=>{De&&U(te.clientX)},Se=te=>{var we;De&&(De=!1,(we=A.hasPointerCapture)!=null&&we.call(A,te.pointerId)&&A.releasePointerCapture(te.pointerId),T.style.scrollSnapType="")};return A.addEventListener("pointerdown",V),A.addEventListener("pointermove",ae),A.addEventListener("pointerup",Se),A.addEventListener("pointercancel",Se),()=>{T.removeEventListener("scroll",oe),re.disconnect(),cancelAnimationFrame(z),A.removeEventListener("pointerdown",V),A.removeEventListener("pointermove",ae),A.removeEventListener("pointerup",Se),A.removeEventListener("pointercancel",Se)}},[k,n]),nr({title:n?a("modelPage.metaTitle")(n.model.brand_name,n.model.name):a("modelPage.metaTitleFallback"),description:n?a("modelPage.metaDescription")(n.model.brand_name,n.model.name):void 0,path:`/fahrzeuge/${e}/${t}`});const K=Be(n?`car_models.${n.model.id}.name`:"");if(o.vehicles.enabled&&!o.bypass)return l.jsx(oi,{message:o.vehicles.message});if(s)return s.status===404?l.jsx(Ed,{}):l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:ma(s,a)});if(!n)return l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:a("modelPage.loading")});const{model:H}=n,$=n.packages.map(T=>({...T,description:Pn(T,"description",u),tagline:Pn(T,"tagline",u),price_text:Pn(T,"price_text",u)})),se=new Map([...$].sort((T,A)=>T.total_price-A.total_price).map((T,A)=>[T.id,A])),G=T=>{const A=T.tier_count??$.length,ie=T.tier_rank??se.get(T.id)??0,z=A<=1?0:ie/(A-1),de=Math.round(z*(v.length-1));return{tier:v[de],tierT:z}},X=T=>[...T.products.map(A=>({text:A.name_override||A.scraped_name||a("modelPage.productLoading"),fromDescription:!1})),...(T.description||"").split(` +`).map(A=>A.trim()).filter(Boolean).map(A=>({text:A,fromDescription:!0}))],N=T=>`/kontakt?${new URLSearchParams({brand:H.brand_name,model:H.name,package:T.name,packageId:T.id,total:T.total_price,brandSlug:e,modelSlug:t}).toString()}`,L=`/kontakt?${new URLSearchParams({brand:H.brand_name,model:H.name}).toString()}`,F=a("modelPage.whatsappText")(H.brand_name,H.name);return l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"mx-auto max-w-6xl px-4 pt-12 sm:px-6",children:[o.vehicles.enabled&&o.bypass&&l.jsx(ai,{inline:!0}),l.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[l.jsx(W,{to:"/fahrzeuge",className:"hover:text-brand-500",children:a("modelPage.breadcrumbVehicles")})," /"," ",l.jsx(W,{to:`/fahrzeuge/${e}`,className:"hover:text-brand-500",children:H.brand_name})," / ",l.jsx("span",{style:K,children:H.name})]}),l.jsxs("h1",{className:`text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl ${$.length?"mb-2":"mb-8"}`,children:[H.brand_name," ",l.jsx("span",{style:K,children:H.name})," – ",a("modelPage.titleSuffix")]}),$.length===0&&l.jsxs("div",{className:"pb-12",children:[l.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("modelPage.empty")}),l.jsx(W,{to:L,className:"mt-5 inline-block rounded-md bg-brand-500 px-5 py-3 text-sm font-semibold text-white shadow-sm hover:bg-brand-600",children:a("modelPage.customRequest")})]})]}),$.length>0&&l.jsx("section",{className:"py-10 sm:py-14",style:{fontFamily:"'Barlow', sans-serif"},children:l.jsxs("div",{className:k==="grid"?"mx-auto max-w-6xl px-4 sm:px-6":"relative mx-auto max-w-[1880px] px-4 sm:px-6",children:[l.jsx("div",{ref:k==="grid"?void 0:C,className:k==="grid"?"grid items-stretch gap-[18px]":"grid select-none gap-x-[18px] overflow-x-auto pb-3 snap-x snap-mandatory [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",style:k==="grid"?{gridTemplateColumns:`repeat(auto-fill, minmax(${h}px, 1fr))`,gridAutoRows:"1fr"}:{gridAutoFlow:"column",gridAutoColumns:`${h}px`,gridTemplateRows:"auto auto 1fr auto",minHeight:`${Number(y)+(k==="coverflow"?22:12)}px`,...k==="coverflow"?{perspective:"1200px",paddingLeft:`calc(50% - ${h/2}px)`,paddingRight:`calc(50% - ${h/2}px)`,paddingTop:"10px"}:null},children:$.map(T=>{const{tier:A,tierT:ie}=G(T);return l.jsx(DE,{pkg:T,tier:A,tierT:ie,layout:k,bullets:X(T),formatPrice:O,contactUrl:N,priceNote:g,t:a},T.id)})}),k!=="grid"&&l.jsx("div",{className:`pointer-events-none absolute inset-x-0 top-1/2 z-[200] flex -translate-y-1/2 justify-center transition-opacity duration-300 ${M?"opacity-100":"opacity-0"}`,"aria-hidden":"true",children:l.jsxs("div",{className:"flex items-center gap-2 rounded-full border border-white/10 bg-neutral-900/85 px-4 py-2 text-xs font-medium text-white shadow-lg backdrop-blur-sm",children:[l.jsx(dC,{className:"h-3.5 w-3.5 text-brand-400"}),l.jsx(RC,{className:"h-4 w-4 text-brand-400"}),l.jsx(hC,{className:"h-3.5 w-3.5 text-brand-400"}),l.jsx("span",{children:a("modelPage.wheelHint")})]})}),k!=="grid"&&l.jsx("div",{ref:j,className:"relative mx-auto mt-5 h-2 w-56 max-w-full cursor-pointer rounded-full bg-neutral-900/10 transition-opacity duration-200 dark:bg-white/10",style:{touchAction:"none"},"aria-hidden":"true",children:l.jsx("div",{ref:P,className:"absolute left-0 top-0 h-full rounded-full bg-brand-500 shadow-[0_0_10px_rgba(107,166,38,0.7)]",style:{width:"48px"}})})]})}),$.length>0&&l.jsxs("div",{className:"mx-auto max-w-6xl px-4 pb-24 text-center sm:px-6 sm:pb-14",children:[l.jsx("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:a("modelPage.customHint")}),l.jsx(W,{to:L,className:"mt-2 inline-block text-sm font-semibold text-brand-600 underline hover:text-brand-500",children:a("modelPage.customRequest")})]}),(x||w)&&l.jsxs("div",{className:"fixed inset-x-0 bottom-0 z-20 flex gap-3 border-t border-neutral-200 bg-white/95 px-4 py-3 shadow-[0_-8px_24px_rgba(0,0,0,0.08)] backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:hidden",children:[x&&l.jsxs("a",{href:Sd(x),onClick:()=>Sn("contact_call"),className:"flex flex-1 items-center justify-center gap-2 rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white",children:[l.jsx(Or,{className:"h-4 w-4"}),a("nav.call")]}),w&&l.jsxs("a",{href:Pd(w,F),target:"_blank",rel:"noopener noreferrer",onClick:()=>Sn("contact_whatsapp"),className:"flex flex-1 items-center justify-center gap-2 rounded-md border border-neutral-300 px-4 py-2.5 text-sm font-semibold text-neutral-700 dark:border-neutral-700 dark:text-neutral-200",children:[l.jsx(dx,{className:"h-4 w-4"}),a("nav.whatsapp")]})]})]})}const IE={car:Oo,caravan:iC,"car-front":nC,cog:wC,zap:eT,boxes:eC,"shield-alert":UC,video:QC},VE=p.lazy(()=>Y(()=>import("./iconRegistry-DrgKxhYw.js"),__vite__mapDeps([0,1,2,3,4])));function FE({name:e,className:t="h-6 w-6",...n}){if(!e)return null;const r=IE[e];return r?l.jsx(r,{className:t,...n}):l.jsx(p.Suspense,{fallback:l.jsx("span",{className:`inline-block ${t}`,"aria-hidden":"true"}),children:l.jsx(VE,{name:e,className:t,...n})})}function OE(){const[e,t]=p.useState([]),n=fa(),{t:r,language:s}=rt();return p.useEffect(()=>{ce.get("/services").then(t).catch(()=>t([]))},[]),nr({title:r("leistungen.metaTitle"),description:r("leistungen.metaDescription"),path:"/leistungen"}),n.services.enabled&&!n.bypass?l.jsx(oi,{message:n.services.message}):l.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[n.services.enabled&&n.bypass&&l.jsx(ai,{inline:!0}),l.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:r("leistungen.title")}),l.jsx("p",{className:"mb-10 max-w-2xl text-neutral-600 dark:text-neutral-300",children:r("leistungen.intro")}),l.jsx("div",{className:"grid gap-5 sm:grid-cols-2 lg:grid-cols-3",children:e.map(i=>({...i,title:Pn(i,"title",s),description:Pn(i,"description",s),cta_label:Pn(i,"cta_label",s)})).map((i,o)=>l.jsxs(ze,{index:o%3,shine:!0,className:"overflow-hidden rounded-xl border border-neutral-200 bg-white dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"relative aspect-[4/3]",children:[i.image_path&&l.jsx("img",{src:i.image_path,alt:i.title,className:"h-full w-full object-cover",loading:"lazy"}),l.jsx("div",{className:"absolute -bottom-5 left-5 flex h-12 w-12 items-center justify-center rounded-full bg-brand-500 text-white shadow-lg ring-4 ring-white dark:ring-neutral-900",children:l.jsx(FE,{name:i.icon_name,className:"h-6 w-6"})})]}),l.jsxs("div",{className:"p-6 pt-8",children:[l.jsx("h2",{className:"mb-2 font-semibold text-neutral-900 dark:text-white",children:i.title}),l.jsx("p",{className:"mb-3 text-sm text-neutral-600 dark:text-neutral-300",children:i.description}),l.jsxs(W,{to:i.cta_url||"/kontakt",className:"text-sm font-semibold text-brand-600 hover:underline dark:text-brand-400",children:[i.cta_label||r("leistungen.contact")," →"]})]})]},i.id))}),l.jsxs("div",{className:"mt-12 rounded-xl border border-neutral-200 bg-neutral-50 p-8 text-center dark:border-neutral-800 dark:bg-neutral-900/40",children:[l.jsx("h2",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:r("leistungen.notListedTitle")}),l.jsx("p",{className:"mb-5 text-neutral-600 dark:text-neutral-300",children:r("leistungen.notListedText")}),l.jsx(W,{to:"/kontakt",className:"inline-block rounded-md bg-brand-500 px-6 py-3 text-sm font-semibold text-white hover:bg-brand-600",children:r("leistungen.contact")})]})]})}function zE({name:e,description:t,className:n="",children:r}){const{consent:s,acceptAll:i,openSettings:o}=Yr();return s.external?r:l.jsxs("div",{className:`flex flex-col items-center justify-center gap-3 rounded-xl border border-neutral-200 bg-neutral-50 p-6 text-center dark:border-neutral-800 dark:bg-neutral-900/40 ${n}`,children:[l.jsx("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:t||`${e} wird erst nach deiner Zustimmung geladen, da dabei Daten an Google übertragen werden.`}),l.jsxs("div",{className:"flex flex-wrap justify-center gap-2",children:[l.jsx("button",{type:"button",onClick:i,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:"Laden erlauben"}),l.jsx("button",{type:"button",onClick:o,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Cookie-Einstellungen"})]})]})}const BE=e=>(e||"").replace(/[^\d+]/g,""),eo={fontFamily:"'Michroma', sans-serif"};function HE({className:e}){return l.jsx("svg",{className:e,viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:l.jsx("path",{d:"M12 2a10 10 0 0 0-8.6 15l-1.3 4.8 5-1.3A10 10 0 1 0 12 2zm0 2a8 8 0 1 1-4.2 14.8l-.3-.2-2.6.7.7-2.5-.2-.3A8 8 0 0 1 12 4zm4.3 9.9c-.2-.1-1.4-.7-1.6-.8s-.4-.1-.5.1l-.7.9c-.1.1-.3.2-.5.1a6.5 6.5 0 0 1-3.2-2.8c-.1-.2 0-.4.1-.5l.4-.5.2-.4v-.4l-.7-1.7c-.2-.4-.4-.4-.5-.4h-.5c-.2 0-.4.1-.6.3-.7.7-.9 1.6-.6 2.7.5 1.7 1.6 3.1 3.4 4.2 1.7 1 2.5 1 3.4.9.5-.1 1.4-.6 1.6-1.1.2-.5.2-1 .1-1.1z"})})}function $E({path:e,className:t}){return l.jsx("svg",{className:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:l.jsx("path",{d:e})})}const UE={premium:"M4 12v3M8 8v11M12 4v16M16 8v11M20 12v3",germany:"M12 12m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0 M12 2v2M12 20v2M2 12h2M20 12h2M5 5l1.5 1.5M17.5 17.5 19 19M19 5l-1.5 1.5M6.5 17.5 5 19",individual:"M6 3h12l4 6-10 12L2 9z M11 3 8 9l4 12 4-12-3-6M2 9h20",experts:"M20 6 9 17l-5-5"};function Um({formatted:e,color:t}){const[n,r]=e.split("€");return l.jsxs("span",{style:{...eo,color:t},children:[n,l.jsx("span",{style:{fontFamily:"'Barlow', sans-serif"},children:"€"}),r]})}function Li({icon:e,label:t,name:n,type:r="text",required:s,value:i,onChange:o,placeholder:a,autoComplete:u,inputMode:c}){return l.jsxs("div",{className:"flex flex-col gap-2",children:[l.jsx("label",{htmlFor:`kf-${n}`,className:"text-xs font-semibold uppercase tracking-[2px]",style:{color:"var(--kf-label)"},children:t}),l.jsxs("div",{className:"relative flex items-center",children:[l.jsx(e,{className:"pointer-events-none absolute left-[14px] h-[17px] w-[17px]",style:{color:"var(--kf-fieldicon)"}}),l.jsx("input",{id:`kf-${n}`,name:n,type:r,required:s,autoComplete:u,inputMode:c,value:i,onChange:o,placeholder:a,className:"w-full rounded-lg border py-3.5 pl-[42px] pr-4 text-[15px] outline-none transition-colors",style:{background:"var(--kf-field)",borderColor:"var(--kf-fieldbrd)",color:"var(--kf-text2)"}})]})]})}function WE(){const[e]=dk(),{phone:t,whatsapp:n,contact_email:r,address_street:s,address_zip:i,address_city:o,business_hours:a,price_note:u,price_note_en:c}=Lt(),{t:d,language:f}=rt(),{consent:h}=Yr(),y=[s,[i,o].filter(Boolean).join(" ")].filter(Boolean).join(", "),x=encodeURIComponent(y),w=`https://www.google.com/maps/dir/?api=1&destination=${x}`,b=vx(a,d("footer.closed")),m=V=>new Intl.NumberFormat(f==="de"?"de-DE":"en-US",{style:"currency",currency:"EUR"}).format(V),[g,v]=p.useState(()=>({name:"",email:"",phone:"",vin:"",message:e.get("topic")||""})),[k,S]=p.useState("idle"),[C,j]=p.useState(""),[P,M]=p.useState([]),[E,O]=p.useState([]),K=p.useRef(Date.now()),H=p.useRef(null),$=e.get("packageId"),se=e.get("brandSlug"),G=e.get("modelSlug"),[X,N]=p.useState(e.get("total")?Number(e.get("total")):null),[L,F]=p.useState(null),T=f==="en"&&c||u;p.useEffect(()=>{!$||!se||!G||ce.get(`/models/${encodeURIComponent(se)}/${encodeURIComponent(G)}/packages`).then(V=>{var Se;const ae=(Se=V==null?void 0:V.packages)==null?void 0:Se.find(te=>String(te.id)===String($));ae&&(N(Number(ae.total_price)),F(ae.price_text||null))}).catch(()=>{})},[$,se,G]),p.useEffect(()=>{if(!$){M([]);return}ce.get(`/packages/${$}/upgrades`).then(M).catch(()=>M([]))},[$]);const A=V=>{O(ae=>ae.includes(V)?ae.filter(Se=>Se!==V):[...ae,V])},ie=P.filter(V=>E.includes(V.id)).reduce((V,ae)=>V+Number(ae.price),0);nr({title:d("contactPage.metaTitle"),description:d("contactPage.metaDescription"),path:"/kontakt"});const z={brand:e.get("brand")||"",model:e.get("model")||"",package:e.get("package")||""},de=!!(z.brand&&z.model&&z.package),oe=!de&&!!(z.brand&&z.model),re=V=>v(ae=>({...ae,[V.target.name]:V.target.value})),De=async V=>{var ae;V.preventDefault(),S("sending"),j("");try{await ce.post("/contact",{...g,website:((ae=V.target.elements.website)==null?void 0:ae.value)||"",fill_ms:Date.now()-K.current,brand_name:z.brand||null,model_name:z.model||null,package_name:z.package||null,product_name:e.get("product")||null,package_id:$||null,package_product_id:e.get("productId")||null,upgrade_ids:E}),S("sent"),v({name:"",email:"",phone:"",vin:"",message:""}),Sn("generate_lead",{package_name:z.package||void 0,value:X||void 0,currency:"EUR"})}catch(Se){j(ma(Se,d)),S("idle")}};p.useEffect(()=>{k==="sent"&&H.current&&(H.current.scrollIntoView({behavior:"smooth",block:"center"}),H.current.focus({preventScroll:!0}))},[k]);const I=de?d("contactPage.whatsappText")(z.brand,z.model,z.package):oe?d("modelPage.whatsappText")(z.brand,z.model):"",U=[{key:"premium",title:d("contactPage.featurePremiumTitle"),sub:d("contactPage.featurePremiumSub")},{key:"germany",title:d("contactPage.featureGermanyTitle"),sub:d("contactPage.featureGermanySub")},{key:"individual",title:d("contactPage.featureIndividualTitle"),sub:d("contactPage.featureIndividualSub")},{key:"experts",title:d("contactPage.featureExpertsTitle"),sub:d("contactPage.featureExpertsSub")}];return l.jsx("div",{className:"kf-page kontakt-sektion relative w-full overflow-hidden px-4 pb-10 sm:px-10",style:{color:"var(--kf-text2)",fontFamily:"'Barlow', sans-serif"},children:l.jsxs("div",{className:"relative z-10 mx-auto max-w-[1280px] pt-10 sm:pt-14",children:[l.jsx("div",{className:"mb-3 text-[13px] font-semibold uppercase tracking-[6px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.heroEyebrow")}),l.jsxs("h1",{className:"text-[34px] leading-[1.08] sm:text-[46px] lg:text-[60px]",style:{...eo,color:"var(--kf-text)"},children:[d("contactPage.heroTitlePre")," ",l.jsx("span",{style:{color:"var(--kf-accent2)"},children:d("contactPage.heroTitleAccent")})," ",d("contactPage.heroTitlePost")]}),l.jsx("p",{className:"mb-10 mt-5 max-w-[520px] text-lg leading-[1.55]",style:{color:"var(--kf-muted)"},children:d("contactPage.heroSubtitle")}),l.jsxs("div",{className:"grid grid-cols-1 items-start gap-10 min-[981px]:grid-cols-[minmax(0,1.35fr)_minmax(320px,1fr)]",children:[l.jsx("div",{children:l.jsxs("div",{className:"rounded-2xl border p-[22px] sm:p-10",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow)"},children:[de&&l.jsxs("div",{className:"mb-8 rounded-xl border px-6 py-[22px]",style:{background:"var(--kf-pkgbg)",borderColor:"var(--kf-pkgbrd)"},children:[l.jsxs("div",{className:"mb-3.5 flex items-center gap-2.5 text-xs font-bold uppercase tracking-[2px]",style:{color:"var(--kf-accent2)"},children:[l.jsx(OC,{className:"h-4 w-4"}),d("contactPage.packageBoxTitle")]}),l.jsxs("div",{className:"grid grid-cols-[auto_1fr] gap-x-5 gap-y-2 text-[15px]",children:[l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.contextBrand")}),l.jsx("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:z.brand}),l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.contextModel")}),l.jsx("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:z.model}),l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.contextPackage")}),l.jsx("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:z.package})]}),l.jsxs("div",{className:"mt-3.5 flex items-baseline justify-between border-t pt-3.5",style:{borderColor:"var(--kf-pkgbrd)"},children:[l.jsx("span",{className:"text-[13px] font-semibold uppercase tracking-wide",style:{color:"var(--kf-muted)"},children:d("contactPage.packagePrice")}),l.jsx("span",{className:"text-xl",children:L||(X!=null?l.jsx(Um,{formatted:m(X),color:"var(--kf-text)"}):"—")})]}),T&&!L&&l.jsx("div",{className:"mt-1 text-right text-xs",style:{color:"var(--kf-muted)"},children:T})]}),oe&&l.jsxs("div",{className:"mb-8 flex items-center gap-3 rounded-xl border px-6 py-4 text-[15px]",style:{background:"var(--kf-pkgbg)",borderColor:"var(--kf-pkgbrd)"},children:[l.jsx(Oo,{className:"h-4 w-4",style:{color:"var(--kf-accent2)"}}),l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.vehicleBoxTitle")}),l.jsxs("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:[z.brand," ",z.model]})]}),P.length>0&&l.jsxs("div",{className:"mb-8 rounded-xl border p-5",style:{background:"var(--kf-field)",borderColor:"var(--kf-fieldbrd)"},children:[l.jsx("div",{className:"mb-3 text-xs font-bold uppercase tracking-[2px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.optionalUpgrades")}),l.jsx("div",{className:"space-y-2",children:P.map(V=>l.jsxs("label",{className:"flex cursor-pointer items-start gap-3 rounded-lg border p-3 text-sm",style:{borderColor:"var(--kf-fieldbrd)"},children:[l.jsx("input",{type:"checkbox",checked:E.includes(V.id),onChange:()=>A(V.id),className:"mt-0.5 h-4 w-4 rounded",style:{accentColor:"var(--kf-accent)"}}),l.jsxs("span",{className:"flex-1",children:[l.jsx("span",{className:"block font-semibold",style:{color:"var(--kf-text2)"},children:Pn(V,"name",f)}),V.description&&l.jsx("span",{className:"block text-xs",style:{color:"var(--kf-muted)"},children:Pn(V,"description",f)})]}),l.jsxs("span",{className:"font-semibold",style:{color:"var(--kf-accent2)"},children:["+",m(V.price)]})]},V.id))}),E.length>0&&X!=null&&!L&&l.jsxs("div",{className:"mt-3 flex items-baseline justify-between border-t pt-3 text-sm",style:{borderColor:"var(--kf-pkgbrd)"},children:[l.jsx("span",{className:"text-xs font-semibold uppercase tracking-wide",style:{color:"var(--kf-muted)"},children:d("contactPage.totalWithUpgrades")}),l.jsx(Um,{formatted:m(X+ie),color:"var(--kf-text)"})]})]}),l.jsx("h2",{className:"mb-8 text-xl",style:{...eo,color:"var(--kf-text)"},children:d("contactPage.formTitle")}),l.jsx("div",{role:"status","aria-live":"polite",children:k==="sent"&&l.jsxs("div",{ref:H,tabIndex:-1,className:"rounded-[10px] border p-5 outline-none",style:{borderColor:"var(--kf-accent)",background:"var(--kf-accentsoft)"},children:[l.jsx("div",{className:"text-base font-bold",style:{color:"var(--kf-accent2)"},children:d("contactPage.sentTitle")}),l.jsx("div",{className:"mt-1 text-sm",style:{color:"var(--kf-muted)"},children:d("contactPage.sentText")}),l.jsx("button",{type:"button",onClick:()=>{K.current=Date.now(),S("idle")},className:"mt-4 text-sm font-semibold underline",style:{color:"var(--kf-text2)"},children:d("contactPage.sendAnother")})]})}),k!=="sent"&&l.jsxs("form",{onSubmit:De,noValidate:!1,children:[l.jsxs("div",{"aria-hidden":"true",style:{position:"absolute",left:"-10000px",width:"1px",height:"1px",overflow:"hidden"},children:[l.jsx("label",{htmlFor:"kf-website",children:"Website"}),l.jsx("input",{id:"kf-website",name:"website",type:"text",tabIndex:-1,autoComplete:"off",defaultValue:""})]}),l.jsxs("div",{className:"grid grid-cols-1 gap-6 min-[641px]:grid-cols-2",children:[l.jsx(Li,{icon:XC,label:d("contactPage.nameLabel"),name:"name",autoComplete:"name",required:!0,value:g.name,onChange:re,placeholder:d("contactPage.namePlaceholder")}),l.jsx(Li,{icon:zu,label:d("contactPage.emailLabel"),name:"email",type:"email",autoComplete:"email",required:!0,value:g.email,onChange:re,placeholder:d("contactPage.emailPlaceholder")}),l.jsx(Li,{icon:Or,label:d("contactPage.phoneLabel"),name:"phone",type:"tel",inputMode:"tel",autoComplete:"tel",value:g.phone,onChange:re,placeholder:d("contactPage.phonePlaceholder")}),l.jsx(Li,{icon:Oo,label:d("contactPage.vinLabel"),name:"vin",value:g.vin,onChange:re,placeholder:d("contactPage.vinPlaceholder")})]}),l.jsxs("div",{className:"mt-6 flex flex-col gap-2",children:[l.jsx("label",{htmlFor:"kf-message",className:"text-xs font-semibold uppercase tracking-[2px]",style:{color:"var(--kf-label)"},children:d("contactPage.messageLabel")}),l.jsx("textarea",{id:"kf-message",name:"message",rows:5,value:g.message,onChange:re,placeholder:d("contactPage.messagePlaceholder"),className:"w-full resize-y rounded-lg border px-4 py-3.5 text-[15px] outline-none",style:{background:"var(--kf-field)",borderColor:"var(--kf-fieldbrd)",color:"var(--kf-text2)"}})]}),l.jsx("div",{role:"alert","aria-live":"assertive",children:C&&l.jsx("p",{className:"mt-4 text-sm text-red-600 dark:text-red-400",children:C})}),l.jsxs("div",{className:"mt-8 flex flex-wrap items-center gap-5",children:[l.jsxs("button",{type:"submit",disabled:k==="sending",className:"inline-flex items-center gap-3 rounded-lg px-8 py-4 text-sm font-bold uppercase tracking-[3px] transition-[filter,box-shadow] hover:brightness-110 disabled:opacity-60",style:{background:"var(--kf-accent)",color:"var(--kf-btntext)",boxShadow:"0 10px 24px rgba(150,200,20,0.32)"},children:[l.jsx(HC,{className:"h-[18px] w-[18px]"}),d(k==="sending"?"contactPage.sending":"contactPage.submit")]}),l.jsx("div",{className:"text-[13px]",style:{color:"var(--kf-label)"},children:d("contactPage.requiredHint")})]}),l.jsxs("p",{className:"mt-5 text-[13px] leading-relaxed",style:{color:"var(--kf-muted)"},children:[d("contactPage.privacyPre"),l.jsx(W,{to:"/datenschutz",className:"underline",style:{color:"var(--kf-text2)"},children:d("contactPage.privacyLink")}),d("contactPage.privacyPost")]})]})]})}),l.jsxs("div",{className:"flex flex-col gap-6",children:[l.jsxs("div",{className:"relative overflow-hidden rounded-2xl border px-[22px] py-[26px] sm:px-8 sm:py-[34px]",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow)"},children:[l.jsx("div",{className:"pointer-events-none absolute -right-[60px] -top-[60px] h-[190px] w-[190px] rounded-full border border-dashed",style:{borderColor:"var(--kf-pkgbrd)"}}),l.jsx("h2",{className:"mb-7 text-[17px]",style:{...eo,color:"var(--kf-text)"},children:d("contactPage.cardTitle")}),l.jsxs("div",{className:"flex flex-col gap-5",children:[l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(Or,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.phone")}),l.jsx("a",{href:`tel:${BE(t)}`,onClick:()=>Sn("contact_call"),className:"text-base font-semibold",style:{color:"var(--kf-text2)"},children:t})]})]}),l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(zu,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.email")}),l.jsx("a",{href:`mailto:${r}`,className:"text-base font-semibold",style:{color:"var(--kf-text2)"},children:r})]})]}),l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(cx,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.address")}),l.jsxs("div",{className:"text-base font-semibold leading-[1.4]",style:{color:"var(--kf-text2)"},children:[s,l.jsx("br",{}),[i,o].filter(Boolean).join(" ")]})]})]}),n&&l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(HE,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("nav.whatsapp")}),l.jsx("a",{href:Pd(n,I),target:"_blank",rel:"noopener noreferrer",onClick:()=>Sn("contact_whatsapp"),className:"text-base font-semibold",style:{color:"var(--kf-text2)"},children:n})]})]})]}),l.jsxs("div",{className:"mt-7 border-t pt-6",style:{borderColor:"var(--kf-divider)"},children:[l.jsx("div",{className:"mb-3 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.hours")}),l.jsx("div",{className:"grid grid-cols-[auto_1fr] gap-x-6 gap-y-2 text-[15px]",children:b.map(V=>l.jsxs("span",{style:{display:"contents"},children:[l.jsx("span",{style:{color:"var(--kf-label)"},children:V.days}),l.jsx("span",{children:V.label})]},V.key))})]})]}),l.jsxs("div",{className:"relative overflow-hidden rounded-2xl border",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow)"},children:[h.external&&l.jsxs("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"absolute left-3.5 top-3.5 z-10 inline-flex items-center gap-2 rounded-lg border px-3.5 py-2 text-[13px] font-semibold hover:border-[var(--kf-accent)]",style:{background:"var(--kf-pill)",borderColor:"var(--kf-pillbrd)",color:"var(--kf-text2)",boxShadow:"var(--kf-shadow2)"},children:[d("contactPage.mapOpenChip"),l.jsx(bC,{className:"h-3.5 w-3.5",style:{color:"var(--kf-accent2)"}})]}),l.jsx(zE,{name:d("contactPage.mapEmbedName"),className:"h-[210px] w-full",children:l.jsx("div",{className:"h-[210px] overflow-hidden",children:l.jsx("iframe",{title:d("contactPage.mapIframeTitle"),src:`https://www.google.com/maps?q=${x}&output=embed`,width:"100%",height:"290",style:{border:0,display:"block",marginTop:"-60px"},loading:"lazy",referrerPolicy:"no-referrer-when-downgrade"})})}),l.jsxs("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2.5 border-t px-4 py-4 text-[13px] font-bold uppercase tracking-[3px] hover:bg-[var(--kf-accentsoft)]",style:{borderColor:"var(--kf-divider)",color:"var(--kf-accent2)"},children:[d("contactPage.routePlan")," →"]})]})]})]}),l.jsx("div",{className:"mt-10 grid grid-cols-1 overflow-hidden rounded-2xl border min-[641px]:grid-cols-2 min-[901px]:grid-cols-4",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow2)"},children:U.map(V=>l.jsxs("div",{className:"flex items-center gap-4 border-b p-6 last:border-b-0 min-[641px]:border-b-0 min-[641px]:border-r min-[641px]:last:border-r-0",style:{borderColor:"var(--kf-divider)"},children:[l.jsx("div",{className:"flex h-[46px] w-[46px] flex-shrink-0 items-center justify-center rounded-full border-[1.5px]",style:{borderColor:"var(--kf-pkgbrd)",color:"var(--kf-accent2)"},children:l.jsx($E,{path:UE[V.key],className:"h-[22px] w-[22px]"})}),l.jsxs("div",{children:[l.jsx("div",{className:"text-[15px] font-bold",style:{color:"var(--kf-text)"},children:V.title}),l.jsx("div",{className:"mt-0.5 text-[13px]",style:{color:"var(--kf-muted)"},children:V.sub})]})]},V.key))})]})})}const dl="hifi-chunk-reload",Q=e=>p.lazy(()=>e().then(t=>{try{sessionStorage.removeItem(dl)}catch{}return t},t=>{let n=!0;try{n=!!sessionStorage.getItem(dl),sessionStorage.setItem(dl,"1")}catch{}if(n)throw t;return window.location.reload(),new Promise(()=>{})})),GE=Q(()=>Y(()=>import("./GalleryOverview-DhSnL2lN.js"),[])),KE=Q(()=>Y(()=>import("./GalleryBrandPage-BhU6Rbz8.js"),[])),qE=Q(()=>Y(()=>import("./GalleryProjectPage-CsTZdUev.js"),[])),YE=Q(()=>Y(()=>import("./DownloadsPage-CMVi3G0A.js"),__vite__mapDeps([5,6,1]))),XE=Q(()=>Y(()=>import("./Impressum-CIqwNdiT.js"),[])),ZE=Q(()=>Y(()=>import("./Datenschutz-CGepmxse.js"),[])),QE=Q(()=>Y(()=>import("./AGB-B90f-gJQ.js"),[])),JE=Q(()=>Y(()=>import("./SetupWizard-BH4s6ZYO.js"),[])),eN=Q(()=>Y(()=>import("./Login-C7DApxPv.js"),[])),tN=Q(()=>Y(()=>import("./Dashboard-Cqfuh4mJ.js"),__vite__mapDeps([7,8,9]))),nN=Q(()=>Y(()=>import("./Brands-CdXOB29N.js"),__vite__mapDeps([10,11,12,13,14,15,3]))),rN=Q(()=>Y(()=>import("./Models-DiJaASky.js"),__vite__mapDeps([16,11,12,13,14,15,3,17]))),sN=Q(()=>Y(()=>import("./GalleryBrands-7-ErMZO-.js"),__vite__mapDeps([18,11,12,14,15,3,17]))),iN=Q(()=>Y(()=>import("./GalleryProjects-NiVXDHl3.js"),__vite__mapDeps([19,11,12,14,15,3,17]))),oN=Q(()=>Y(()=>import("./GalleryPhotos-CuXZZ7cQ.js"),__vite__mapDeps([20,14,15,3,17,12]))),aN=Q(()=>Y(()=>import("./Packages-N3XayAy4.js"),__vite__mapDeps([21,13,17,15,4,3,2]))),lN=Q(()=>Y(()=>import("./Services-BuFoA76N.js"),__vite__mapDeps([22,14,15,3,17,11,12,0,1,2,4]))),uN=Q(()=>Y(()=>import("./Faqs-Mcg7d29g.js"),__vite__mapDeps([23,14,15,3,17]))),cN=Q(()=>Y(()=>import("./Partners-B5umAj33.js"),__vite__mapDeps([24,11,12,14,15,3,17]))),dN=Q(()=>Y(()=>import("./Downloads-BM4-wi1i.js"),__vite__mapDeps([25,6,14,15,3,17,2]))),fN=Q(()=>Y(()=>import("./HomeSections-WAiTz48-.js"),__vite__mapDeps([26,27,13,28]))),hN=Q(()=>Y(()=>import("./ContactRequests-D4KmPFzX.js"),__vite__mapDeps([29,9]))),mN=Q(()=>Y(()=>import("./AccountSettings-D6J5mj1V.js"),[])),pN=Q(()=>Y(()=>import("./AdminUsers-KKeTcWes.js"),[])),gN=Q(()=>Y(()=>import("./PermissionGroups-C919vkqw.js"),[])),yN=Q(()=>Y(()=>import("./SettingsLayout-Cbd5Mqx8.js"),[])),fl=Q(()=>Y(()=>import("./WebsiteSettings-I9lUY-Do.js"),__vite__mapDeps([30,11,12,28]))),xN=Q(()=>Y(()=>import("./LegalSettings-53BO_3BR.js"),__vite__mapDeps([31,27]))),vN=Q(()=>Y(()=>import("./UpdateSettings-CYjkz_68.js"),[])),wN=Q(()=>Y(()=>import("./EmailSettings-Bbg5xyAa.js"),__vite__mapDeps([32,27]))),kN=Q(()=>Y(()=>import("./DatabaseSettings-CivwQ4EI.js"),__vite__mapDeps([33,8]))),bN=Q(()=>Y(()=>import("./ExportImportSettings-uCQ9DCjI.js"),[])),SN=Q(()=>Y(()=>import("./MaintenanceSettings-CgC3Xndt.js"),[])),PN=Q(()=>Y(()=>import("./ResetSettings-Be0-Za-k.js"),[])),jN=l.jsx("div",{className:"min-h-screen bg-white dark:bg-neutral-950"});function CN(){const{packageId:e}=Bc();return l.jsx(Zn,{to:`/admin/packages?paket=${e}`,replace:!0})}function TN(){return l.jsxs(lP,{reducedMotion:"user",children:[l.jsx(Fj,{}),l.jsx(Bj,{}),l.jsx(Kj,{children:l.jsx(p.Suspense,{fallback:jN,children:l.jsxs(Xw,{children:[l.jsx(B,{path:"/setup",element:l.jsx(JE,{})}),l.jsxs(B,{element:l.jsx(GT,{}),children:[l.jsx(B,{path:"/",element:l.jsx(yE,{})}),l.jsx(B,{path:"/fahrzeuge",element:l.jsx(xE,{})}),l.jsx(B,{path:"/fahrzeuge/:brandSlug",element:l.jsx(vE,{})}),l.jsx(B,{path:"/fahrzeuge/:brandSlug/:modelSlug",element:l.jsx(RE,{})}),l.jsx(B,{path:"/galerie",element:l.jsx(GE,{})}),l.jsx(B,{path:"/galerie/:brandSlug",element:l.jsx(KE,{})}),l.jsx(B,{path:"/galerie/:brandSlug/:projectSlug",element:l.jsx(qE,{})}),l.jsx(B,{path:"/leistungen",element:l.jsx(OE,{})}),l.jsx(B,{path:"/kontakt",element:l.jsx(WE,{})}),l.jsx(B,{path:"/downloads",element:l.jsx(YE,{})}),l.jsx(B,{path:"/impressum",element:l.jsx(XE,{})}),l.jsx(B,{path:"/datenschutz",element:l.jsx(ZE,{})}),l.jsx(B,{path:"/agb",element:l.jsx(QE,{})}),l.jsx(B,{path:"*",element:l.jsx(Ed,{})})]}),l.jsx(B,{path:"/admin/login",element:l.jsx(eN,{})}),l.jsx(B,{path:"/admin",element:l.jsx(JT,{}),children:l.jsxs(B,{element:l.jsx(QT,{}),children:[l.jsx(B,{index:!0,element:l.jsx(tN,{})}),l.jsx(B,{path:"account",element:l.jsx(mN,{})}),l.jsx(B,{path:"brands",element:l.jsx(fe,{permission:"brands.manage",children:l.jsx(nN,{})})}),l.jsx(B,{path:"models",element:l.jsx(fe,{permission:"models.manage",children:l.jsx(rN,{})})}),l.jsx(B,{path:"gallery-brands",element:l.jsx(fe,{permission:"gallery.manage",children:l.jsx(sN,{})})}),l.jsx(B,{path:"gallery-projects",element:l.jsx(fe,{permission:"gallery.manage",children:l.jsx(iN,{})})}),l.jsx(B,{path:"gallery-projects/:projectId/photos",element:l.jsx(fe,{permission:"gallery.manage",children:l.jsx(oN,{})})}),l.jsx(B,{path:"packages",element:l.jsx(fe,{permission:"packages.manage",children:l.jsx(aN,{})})}),l.jsx(B,{path:"packages/:packageId/*",element:l.jsx(CN,{})}),l.jsx(B,{path:"services",element:l.jsx(fe,{permission:"services.manage",children:l.jsx(lN,{})})}),l.jsx(B,{path:"faqs",element:l.jsx(fe,{permission:"content.manage",children:l.jsx(uN,{})})}),l.jsx(B,{path:"partners",element:l.jsx(fe,{permission:"content.manage",children:l.jsx(cN,{})})}),l.jsx(B,{path:"downloads",element:l.jsx(fe,{permission:"downloads.manage",children:l.jsx(dN,{})})}),l.jsx(B,{path:"home-sections",element:l.jsx(fe,{permission:"content.manage",children:l.jsx(fN,{})})}),l.jsx(B,{path:"contact-requests",element:l.jsx(fe,{permission:"contact.manage",children:l.jsx(hN,{})})}),l.jsx(B,{path:"users",element:l.jsx(fe,{permission:"users.manage",children:l.jsx(pN,{})})}),l.jsx(B,{path:"permission-groups",element:l.jsx(fe,{permission:"permission_groups.manage",children:l.jsx(gN,{})})}),l.jsxs(B,{path:"settings",element:l.jsx(fe,{permission:["settings.manage","system.admin","system.update"],children:l.jsx(yN,{})}),children:[l.jsx(B,{index:!0,element:l.jsx(Zn,{to:"company",replace:!0})}),l.jsx(B,{path:"website",element:l.jsx(Zn,{to:"../company",replace:!0})}),l.jsx(B,{path:"company",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(fl,{section:"company"})})}),l.jsx(B,{path:"design",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(fl,{section:"design"})})}),l.jsx(B,{path:"legal",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(xN,{})})}),l.jsx(B,{path:"maintenance",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(SN,{})})}),l.jsx(B,{path:"google",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(fl,{section:"google"})})}),l.jsx(B,{path:"email",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(wN,{})})}),l.jsx(B,{path:"database",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(kN,{})})}),l.jsx(B,{path:"export-import",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(bN,{})})}),l.jsx(B,{path:"update",element:l.jsx(fe,{permission:"system.update",children:l.jsx(vN,{})})}),l.jsx(B,{path:"reset",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(PN,{})})})]})]})})]})})})]})}hl.createRoot(document.getElementById("root")).render(l.jsx(np.StrictMode,{children:l.jsx(ik,{basename:"/".replace(/\/$/,"")||"/",children:l.jsx(nT,{children:l.jsx(aT,{children:l.jsx(pT,{children:l.jsx(TN,{})})})})})}));export{dx as $,Hj as A,Wm as B,yC as C,FE as D,bC as E,EN as F,ee as G,eC as H,Oo as I,nC as J,iC as K,W as L,aC as M,Ed as N,Hc as O,dC as P,pC as Q,ze as R,jx as S,ux as T,wC as U,PC as V,CC as W,EC as X,_C as Y,zu as Z,cx as _,Lt as a,RC as a0,VC as a1,OC as a2,Or as a3,HC as a4,UC as a5,GC as a6,qC as a7,XC as a8,QC as a9,eT as aa,Qj as ab,_N as ac,Zj as ad,nr as b,ce as c,Vm as d,ma as e,Bc as f,Vc as g,qr as h,sa as i,l as j,Zn as k,Lm as l,Hu as m,AN as n,DN as o,RN as p,dk as q,p as r,uC as s,hC as t,rt as u,np as v,LN as w,nt as x,Sx as y,MN as z}; diff --git a/hifi/assets/index-DHXx7jvu.css b/hifi/assets/index-DHXx7jvu.css deleted file mode 100644 index e147343..0000000 --- a/hifi/assets/index-DHXx7jvu.css +++ /dev/null @@ -1 +0,0 @@ -@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/barlow-vietnamese-400-normal-Dpl4UHAZ.woff2) format("woff2"),url(/assets/barlow-vietnamese-400-normal-BFeobeCK.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/barlow-latin-ext-400-normal-HxX4XjxC.woff2) format("woff2"),url(/assets/barlow-latin-ext-400-normal-CvBsJvxq.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/barlow-latin-400-normal-qiz4-Cze.woff2) format("woff2"),url(/assets/barlow-latin-400-normal-fsAxiSwU.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-vietnamese-500-normal-zTViEIzf.woff2) format("woff2"),url(/assets/barlow-vietnamese-500-normal-GNfB7rCE.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-latin-ext-500-normal-DOaysfXq.woff2) format("woff2"),url(/assets/barlow-latin-ext-500-normal-CJPcKP2Q.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-latin-500-normal-BPAOfeC8.woff2) format("woff2"),url(/assets/barlow-latin-500-normal-C1h8hMer.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-vietnamese-600-normal-DcjprdFV.woff2) format("woff2"),url(/assets/barlow-vietnamese-600-normal-CA_GiK2e.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-latin-ext-600-normal-B8NK_A3D.woff2) format("woff2"),url(/assets/barlow-latin-ext-600-normal-DMVRjfRT.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-latin-600-normal-DILqtrty.woff2) format("woff2"),url(/assets/barlow-latin-600-normal-CNwfPWQD.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:700;src:url(/assets/barlow-vietnamese-700-normal-D6euyNzi.woff2) format("woff2"),url(/assets/barlow-vietnamese-700-normal-4Jt4k04K.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:700;src:url(/assets/barlow-latin-ext-700-normal-BLuWmldJ.woff2) format("woff2"),url(/assets/barlow-latin-ext-700-normal-CctuGmmz.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:700;src:url(/assets/barlow-latin-700-normal-A9pxMQ4z.woff2) format("woff2"),url(/assets/barlow-latin-700-normal-__SGTsZ1.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-condensed-vietnamese-500-normal-DjeaNLFD.woff2) format("woff2"),url(/assets/barlow-condensed-vietnamese-500-normal-CsrJDWc5.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-condensed-latin-ext-500-normal-yA5ONLQ9.woff2) format("woff2"),url(/assets/barlow-condensed-latin-ext-500-normal-B1RE8WP7.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-condensed-latin-500-normal-BgYH2mbd.woff2) format("woff2"),url(/assets/barlow-condensed-latin-500-normal-HIEiP5Ov.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-condensed-vietnamese-600-normal-A5AYRdjN.woff2) format("woff2"),url(/assets/barlow-condensed-vietnamese-600-normal-CNlPk46_.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-condensed-latin-ext-600-normal-18ESti3H.woff2) format("woff2"),url(/assets/barlow-condensed-latin-ext-600-normal-Clv9cIcR.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-condensed-latin-600-normal-DepVgxBB.woff2) format("woff2"),url(/assets/barlow-condensed-latin-600-normal-BFJEwTuo.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Michroma;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/michroma-latin-ext-400-normal-BeYM1uOO.woff2) format("woff2"),url(/assets/michroma-latin-ext-400-normal-DlRaauac.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Michroma;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/michroma-latin-400-normal-4gS0VCia.woff2) format("woff2"),url(/assets/michroma-latin-400-normal-C7Pn7qca.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:var(--site-font, ui-sans-serif, system-ui, sans-serif);font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.\!container{width:100%!important}.container{width:100%}@media (min-width: 640px){.\!container{max-width:640px!important}.container{max-width:640px}}@media (min-width: 768px){.\!container{max-width:768px!important}.container{max-width:768px}}@media (min-width: 1024px){.\!container{max-width:1024px!important}.container{max-width:1024px}}@media (min-width: 1280px){.\!container{max-width:1280px!important}.container{max-width:1280px}}@media (min-width: 1536px){.\!container{max-width:1536px!important}.container{max-width:1536px}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.\!visible{visibility:visible!important}.visible{visibility:visible}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.inset-x-0{left:0;right:0}.inset-y-0{top:0;bottom:0}.-bottom-5{bottom:-1.25rem}.-left-1\/3{left:-33.333333%}.-right-1{right:-.25rem}.-right-1\.5{right:-.375rem}.-right-\[60px\]{right:-60px}.-top-1{top:-.25rem}.-top-1\.5{top:-.375rem}.-top-3{top:-.75rem}.-top-\[60px\]{top:-60px}.bottom-0{bottom:0}.bottom-4{bottom:1rem}.left-0{left:0}.left-1{left:.25rem}.left-1\/2{left:50%}.left-2{left:.5rem}.left-3\.5{left:.875rem}.left-5{left:1.25rem}.left-6{left:1.5rem}.left-\[14px\]{left:14px}.right-0{right:0}.right-2{right:.5rem}.right-4{right:1rem}.top-0{top:0}.top-1{top:.25rem}.top-1\/2{top:50%}.top-2{top:.5rem}.top-3\.5{top:.875rem}.top-4{top:1rem}.top-8{top:2rem}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\[100\]{z-index:100}.z-\[200\]{z-index:200}.z-\[300\]{z-index:300}.z-\[400\]{z-index:400}.z-\[60\]{z-index:60}.order-1{order:1}.order-2{order:2}.col-span-full{grid-column:1 / -1}.-mx-4{margin-left:-1rem;margin-right:-1rem}.mx-1{margin-left:.25rem;margin-right:.25rem}.mx-auto{margin-left:auto;margin-right:auto}.-mt-\[89px\]{margin-top:-89px}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-10{margin-bottom:2.5rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-3\.5{margin-bottom:.875rem}.mb-4{margin-bottom:1rem}.mb-5{margin-bottom:1.25rem}.mb-6{margin-bottom:1.5rem}.mb-7{margin-bottom:1.75rem}.mb-8{margin-bottom:2rem}.ml-1{margin-left:.25rem}.ml-2{margin-left:.5rem}.ml-auto{margin-left:auto}.mr-1{margin-right:.25rem}.mr-3{margin-right:.75rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-10{margin-top:2.5rem}.mt-12{margin-top:3rem}.mt-2{margin-top:.5rem}.mt-2\.5{margin-top:.625rem}.mt-3{margin-top:.75rem}.mt-3\.5{margin-top:.875rem}.mt-4{margin-top:1rem}.mt-5{margin-top:1.25rem}.mt-6{margin-top:1.5rem}.mt-7{margin-top:1.75rem}.mt-8{margin-top:2rem}.mt-auto{margin-top:auto}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.line-clamp-6{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:6}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.contents{display:contents}.\!hidden{display:none!important}.hidden{display:none}.aspect-\[4\/3\]{aspect-ratio:4/3}.aspect-square{aspect-ratio:1 / 1}.aspect-video{aspect-ratio:16 / 9}.h-0\.5{height:.125rem}.h-1\.5{height:.375rem}.h-10{height:2.5rem}.h-11{height:2.75rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-24{height:6rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-4{height:1rem}.h-48{height:12rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-7{height:1.75rem}.h-8{height:2rem}.h-80{height:20rem}.h-9{height:2.25rem}.h-\[17px\]{height:17px}.h-\[18px\]{height:18px}.h-\[190px\]{height:190px}.h-\[210px\]{height:210px}.h-\[22px\]{height:22px}.h-\[46px\]{height:46px}.h-fit{height:-moz-fit-content;height:fit-content}.h-full{height:100%}.h-px{height:1px}.h-svh{height:100svh}.max-h-64{max-height:16rem}.max-h-\[85vh\]{max-height:85vh}.min-h-\[10rem\]{min-height:10rem}.min-h-\[560px\]{min-height:560px}.min-h-\[60vh\]{min-height:60vh}.min-h-\[70vh\]{min-height:70vh}.min-h-full{min-height:100%}.min-h-screen{min-height:100vh}.w-1\.5{width:.375rem}.w-1\/3{width:33.333333%}.w-10{width:2.5rem}.w-11{width:2.75rem}.w-12{width:3rem}.w-16{width:4rem}.w-24{width:6rem}.w-28{width:7rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-4{width:1rem}.w-44{width:11rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-60{width:15rem}.w-64{width:16rem}.w-7{width:1.75rem}.w-8{width:2rem}.w-9{width:2.25rem}.w-\[17px\]{width:17px}.w-\[18px\]{width:18px}.w-\[190px\]{width:190px}.w-\[22px\]{width:22px}.w-\[46px\]{width:46px}.w-\[min\(92vw\,380px\)\]{width:min(92vw,380px)}.w-auto{width:auto}.w-full{width:100%}.w-max{width:-moz-max-content;width:max-content}.w-px{width:1px}.min-w-0{min-width:0px}.min-w-\[220px\]{min-width:220px}.min-w-\[640px\]{min-width:640px}.min-w-\[90px\]{min-width:90px}.min-w-\[9rem\]{min-width:9rem}.max-w-2xl{max-width:42rem}.max-w-3xl{max-width:48rem}.max-w-4xl{max-width:56rem}.max-w-6xl{max-width:72rem}.max-w-\[1280px\]{max-width:1280px}.max-w-\[160px\]{max-width:160px}.max-w-\[1880px\]{max-width:1880px}.max-w-\[520px\]{max-width:520px}.max-w-\[85\%\]{max-width:85%}.max-w-\[8rem\]{max-width:8rem}.max-w-\[calc\(100\%-16px\)\]{max-width:calc(100% - 16px)}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-sm{max-width:24rem}.max-w-xl{max-width:36rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.flex-shrink-0,.shrink-0{flex-shrink:0}.origin-left{transform-origin:left}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-12{--tw-rotate: 12deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate: 180deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-grab{cursor:grab}.cursor-grabbing{cursor:grabbing}.cursor-pointer{cursor:pointer}.touch-none{touch-action:none}.touch-pan-y{--tw-pan-y: pan-y;touch-action:var(--tw-pan-x) var(--tw-pan-y) var(--tw-pinch-zoom)}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-y{resize:vertical}.snap-x{scroll-snap-type:x var(--tw-scroll-snap-strictness)}.snap-mandatory{--tw-scroll-snap-strictness: mandatory}.snap-start{scroll-snap-align:start}.snap-center{scroll-snap-align:center}.scroll-mt-20{scroll-margin-top:5rem}.scroll-mt-4{scroll-margin-top:1rem}.list-decimal{list-style-type:decimal}.list-disc{list-style-type:disc}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.grid-cols-\[1fr_auto_1fr\]{grid-template-columns:1fr auto 1fr}.grid-cols-\[auto_1fr\]{grid-template-columns:auto 1fr}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.items-baseline{align-items:baseline}.items-stretch{align-items:stretch}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-10{gap:2.5rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-5{gap:1.25rem}.gap-6{gap:1.5rem}.gap-8{gap:2rem}.gap-\[18px\]{gap:18px}.gap-x-2{-moz-column-gap:.5rem;column-gap:.5rem}.gap-x-3{-moz-column-gap:.75rem;column-gap:.75rem}.gap-x-5{-moz-column-gap:1.25rem;column-gap:1.25rem}.gap-x-6{-moz-column-gap:1.5rem;column-gap:1.5rem}.gap-x-8{-moz-column-gap:2rem;column-gap:2rem}.gap-x-\[18px\]{-moz-column-gap:18px;column-gap:18px}.gap-y-1{row-gap:.25rem}.gap-y-2{row-gap:.5rem}.gap-y-3{row-gap:.75rem}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-16>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(4rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(4rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.space-y-5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.25rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse: 0;border-top-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(1px * var(--tw-divide-y-reverse))}.divide-neutral-100>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(245 245 245 / var(--tw-divide-opacity, 1))}.divide-neutral-200>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(229 229 229 / var(--tw-divide-opacity, 1))}.justify-self-start{justify-self:start}.justify-self-end{justify-self:end}.justify-self-center{justify-self:center}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-line{white-space:pre-line}.whitespace-pre-wrap{white-space:pre-wrap}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-\[10px\]{border-radius:10px}.rounded-\[18px\]{border-radius:18px}.rounded-\[3px\]{border-radius:3px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-xl{border-radius:.75rem}.rounded-b-xl{border-bottom-right-radius:.75rem;border-bottom-left-radius:.75rem}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-0{border-width:0px}.border-4{border-width:4px}.border-\[1\.5px\]{border-width:1.5px}.border-y{border-top-width:1px;border-bottom-width:1px}.border-b{border-bottom-width:1px}.border-r{border-right-width:1px}.border-t{border-top-width:1px}.border-dashed{border-style:dashed}.border-amber-200{--tw-border-opacity: 1;border-color:rgb(253 230 138 / var(--tw-border-opacity, 1))}.border-amber-300{--tw-border-opacity: 1;border-color:rgb(252 211 77 / var(--tw-border-opacity, 1))}.border-brand-500{--tw-border-opacity: 1;border-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.border-green-200{--tw-border-opacity: 1;border-color:rgb(187 247 208 / var(--tw-border-opacity, 1))}.border-neutral-100{--tw-border-opacity: 1;border-color:rgb(245 245 245 / var(--tw-border-opacity, 1))}.border-neutral-200{--tw-border-opacity: 1;border-color:rgb(229 229 229 / var(--tw-border-opacity, 1))}.border-neutral-300{--tw-border-opacity: 1;border-color:rgb(212 212 212 / var(--tw-border-opacity, 1))}.border-neutral-700{--tw-border-opacity: 1;border-color:rgb(64 64 64 / var(--tw-border-opacity, 1))}.border-neutral-800{--tw-border-opacity: 1;border-color:rgb(38 38 38 / var(--tw-border-opacity, 1))}.border-red-200{--tw-border-opacity: 1;border-color:rgb(254 202 202 / var(--tw-border-opacity, 1))}.border-red-300{--tw-border-opacity: 1;border-color:rgb(252 165 165 / var(--tw-border-opacity, 1))}.border-transparent{border-color:transparent}.border-white\/10{border-color:#ffffff1a}.border-white\/15{border-color:#ffffff26}.border-white\/30{border-color:#ffffff4d}.border-white\/40{border-color:#fff6}.border-t-brand-500{--tw-border-opacity: 1;border-top-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.bg-amber-100{--tw-bg-opacity: 1;background-color:rgb(254 243 199 / var(--tw-bg-opacity, 1))}.bg-amber-400{--tw-bg-opacity: 1;background-color:rgb(251 191 36 / var(--tw-bg-opacity, 1))}.bg-amber-50{--tw-bg-opacity: 1;background-color:rgb(255 251 235 / var(--tw-bg-opacity, 1))}.bg-amber-500{--tw-bg-opacity: 1;background-color:rgb(245 158 11 / var(--tw-bg-opacity, 1))}.bg-black\/50{background-color:#00000080}.bg-black\/55{background-color:#0000008c}.bg-black\/60{background-color:#0009}.bg-black\/70{background-color:#000000b3}.bg-black\/90{background-color:#000000e6}.bg-brand-100{--tw-bg-opacity: 1;background-color:rgb(233 246 218 / var(--tw-bg-opacity, 1))}.bg-brand-400{--tw-bg-opacity: 1;background-color:rgb(146 212 68 / var(--tw-bg-opacity, 1))}.bg-brand-50{--tw-bg-opacity: 1;background-color:rgb(245 251 238 / var(--tw-bg-opacity, 1))}.bg-brand-500{--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.bg-brand-500\/10{background-color:#6ba6261a}.bg-brand-500\/60{background-color:#6ba62699}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231 / var(--tw-bg-opacity, 1))}.bg-green-50{--tw-bg-opacity: 1;background-color:rgb(240 253 244 / var(--tw-bg-opacity, 1))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity, 1))}.bg-neutral-100{--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.bg-neutral-200{--tw-bg-opacity: 1;background-color:rgb(229 229 229 / var(--tw-bg-opacity, 1))}.bg-neutral-300{--tw-bg-opacity: 1;background-color:rgb(212 212 212 / var(--tw-bg-opacity, 1))}.bg-neutral-400{--tw-bg-opacity: 1;background-color:rgb(163 163 163 / var(--tw-bg-opacity, 1))}.bg-neutral-50{--tw-bg-opacity: 1;background-color:rgb(250 250 250 / var(--tw-bg-opacity, 1))}.bg-neutral-800{--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.bg-neutral-900{--tw-bg-opacity: 1;background-color:rgb(23 23 23 / var(--tw-bg-opacity, 1))}.bg-neutral-900\/10{background-color:#1717171a}.bg-neutral-900\/85{background-color:#171717d9}.bg-neutral-950{--tw-bg-opacity: 1;background-color:rgb(10 10 10 / var(--tw-bg-opacity, 1))}.bg-neutral-950\/90{background-color:#0a0a0ae6}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226 / var(--tw-bg-opacity, 1))}.bg-red-50{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.bg-red-50\/40{background-color:#fef2f266}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.bg-sky-500{--tw-bg-opacity: 1;background-color:rgb(14 165 233 / var(--tw-bg-opacity, 1))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\/10{background-color:#ffffff1a}.bg-white\/5{background-color:#ffffff0d}.bg-white\/95{background-color:#fffffff2}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.bg-gradient-to-r{background-image:linear-gradient(to right,var(--tw-gradient-stops))}.bg-gradient-to-t{background-image:linear-gradient(to top,var(--tw-gradient-stops))}.from-black\/70{--tw-gradient-from: rgb(0 0 0 / .7) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-black\/85{--tw-gradient-from: rgb(0 0 0 / .85) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-neutral-700{--tw-gradient-from: #404040 var(--tw-gradient-from-position);--tw-gradient-to: rgb(64 64 64 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-neutral-950{--tw-gradient-from: #0a0a0a var(--tw-gradient-from-position);--tw-gradient-to: rgb(10 10 10 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-transparent{--tw-gradient-from: transparent var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.via-black\/10{--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(0 0 0 / .1) var(--tw-gradient-via-position), var(--tw-gradient-to)}.via-black\/20{--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(0 0 0 / .2) var(--tw-gradient-via-position), var(--tw-gradient-to)}.via-neutral-950\/80{--tw-gradient-to: rgb(10 10 10 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(10 10 10 / .8) var(--tw-gradient-via-position), var(--tw-gradient-to)}.via-white\/40{--tw-gradient-to: rgb(255 255 255 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(255 255 255 / .4) var(--tw-gradient-via-position), var(--tw-gradient-to)}.to-black\/40{--tw-gradient-to: rgb(0 0 0 / .4) var(--tw-gradient-to-position)}.to-neutral-900{--tw-gradient-to: #171717 var(--tw-gradient-to-position)}.to-neutral-950\/40{--tw-gradient-to: rgb(10 10 10 / .4) var(--tw-gradient-to-position)}.to-transparent{--tw-gradient-to: transparent var(--tw-gradient-to-position)}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0\.5{padding:.125rem}.p-1{padding:.25rem}.p-1\.5{padding:.375rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.p-8{padding:2rem}.p-\[22px\]{padding:22px}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.px-\[22px\]{padding-left:22px;padding-right:22px}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-16{padding-top:4rem;padding-bottom:4rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-20{padding-top:5rem;padding-bottom:5rem}.py-24{padding-top:6rem;padding-bottom:6rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-3\.5{padding-top:.875rem;padding-bottom:.875rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-8{padding-top:2rem;padding-bottom:2rem}.py-\[22px\]{padding-top:22px;padding-bottom:22px}.py-\[26px\]{padding-top:26px;padding-bottom:26px}.pb-10{padding-bottom:2.5rem}.pb-12{padding-bottom:3rem}.pb-24{padding-bottom:6rem}.pb-3{padding-bottom:.75rem}.pb-4{padding-bottom:1rem}.pb-5{padding-bottom:1.25rem}.pb-6{padding-bottom:1.5rem}.pl-5{padding-left:1.25rem}.pl-6{padding-left:1.5rem}.pl-\[42px\]{padding-left:42px}.pr-4{padding-right:1rem}.pr-8{padding-right:2rem}.pt-0\.5{padding-top:.125rem}.pt-1{padding-top:.25rem}.pt-10{padding-top:2.5rem}.pt-12{padding-top:3rem}.pt-3{padding-top:.75rem}.pt-3\.5{padding-top:.875rem}.pt-4{padding-top:1rem}.pt-5{padding-top:1.25rem}.pt-6{padding-top:1.5rem}.pt-8{padding-top:2rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.font-sans{font-family:var(--site-font, ui-sans-serif, system-ui, sans-serif)}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-\[10px\]{font-size:10px}.text-\[11px\]{font-size:11px}.text-\[13px\]{font-size:13px}.text-\[15px\]{font-size:15px}.text-\[17px\]{font-size:17px}.text-\[34px\]{font-size:34px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-extrabold{font-weight:800}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.normal-case{text-transform:none}.italic{font-style:italic}.leading-\[1\.08\]{line-height:1.08}.leading-\[1\.4\]{line-height:1.4}.leading-\[1\.55\]{line-height:1.55}.leading-none{line-height:1}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.tracking-\[0\.2em\]{letter-spacing:.2em}.tracking-\[2px\]{letter-spacing:2px}.tracking-\[3px\]{letter-spacing:3px}.tracking-\[4px\]{letter-spacing:4px}.tracking-\[6px\]{letter-spacing:6px}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.tracking-wider{letter-spacing:.05em}.tracking-widest{letter-spacing:.1em}.text-amber-400{--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.text-amber-600{--tw-text-opacity: 1;color:rgb(217 119 6 / var(--tw-text-opacity, 1))}.text-amber-700{--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity, 1))}.text-amber-800{--tw-text-opacity: 1;color:rgb(146 64 14 / var(--tw-text-opacity, 1))}.text-amber-900{--tw-text-opacity: 1;color:rgb(120 53 15 / var(--tw-text-opacity, 1))}.text-brand-300{--tw-text-opacity: 1;color:rgb(182 227 130 / var(--tw-text-opacity, 1))}.text-brand-400{--tw-text-opacity: 1;color:rgb(146 212 68 / var(--tw-text-opacity, 1))}.text-brand-500{--tw-text-opacity: 1;color:rgb(107 166 38 / var(--tw-text-opacity, 1))}.text-brand-500\/10{color:#6ba6261a}.text-brand-600{--tw-text-opacity: 1;color:rgb(88 137 31 / var(--tw-text-opacity, 1))}.text-brand-700{--tw-text-opacity: 1;color:rgb(72 112 26 / var(--tw-text-opacity, 1))}.text-brand-800{--tw-text-opacity: 1;color:rgb(59 91 21 / var(--tw-text-opacity, 1))}.text-green-600{--tw-text-opacity: 1;color:rgb(22 163 74 / var(--tw-text-opacity, 1))}.text-green-700{--tw-text-opacity: 1;color:rgb(21 128 61 / var(--tw-text-opacity, 1))}.text-green-800{--tw-text-opacity: 1;color:rgb(22 101 52 / var(--tw-text-opacity, 1))}.text-neutral-200{--tw-text-opacity: 1;color:rgb(229 229 229 / var(--tw-text-opacity, 1))}.text-neutral-300{--tw-text-opacity: 1;color:rgb(212 212 212 / var(--tw-text-opacity, 1))}.text-neutral-400{--tw-text-opacity: 1;color:rgb(163 163 163 / var(--tw-text-opacity, 1))}.text-neutral-500{--tw-text-opacity: 1;color:rgb(115 115 115 / var(--tw-text-opacity, 1))}.text-neutral-600{--tw-text-opacity: 1;color:rgb(82 82 82 / var(--tw-text-opacity, 1))}.text-neutral-700{--tw-text-opacity: 1;color:rgb(64 64 64 / var(--tw-text-opacity, 1))}.text-neutral-800{--tw-text-opacity: 1;color:rgb(38 38 38 / var(--tw-text-opacity, 1))}.text-neutral-900{--tw-text-opacity: 1;color:rgb(23 23 23 / var(--tw-text-opacity, 1))}.text-neutral-950{--tw-text-opacity: 1;color:rgb(10 10 10 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.text-red-700{--tw-text-opacity: 1;color:rgb(185 28 28 / var(--tw-text-opacity, 1))}.text-red-800{--tw-text-opacity: 1;color:rgb(153 27 27 / var(--tw-text-opacity, 1))}.text-slate-900{--tw-text-opacity: 1;color:rgb(15 23 42 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-white\/70{color:#ffffffb3}.text-white\/80{color:#fffc}.text-white\/90{color:#ffffffe6}.underline{text-decoration-line:underline}.line-through{text-decoration-line:line-through}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\[0_-8px_24px_rgba\(0\,0\,0\,0\.08\)\]{--tw-shadow: 0 -8px 24px rgba(0,0,0,.08);--tw-shadow-colored: 0 -8px 24px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\[0_0_10px_rgba\(107\,166\,38\,0\.7\)\]{--tw-shadow: 0 0 10px rgba(107,166,38,.7);--tw-shadow-colored: 0 0 10px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-brand-500\/30{--tw-shadow-color: rgb(107 166 38 / .3);--tw-shadow: var(--tw-shadow-colored)}.shadow-neutral-900\/20{--tw-shadow-color: rgb(23 23 23 / .2);--tw-shadow: var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-4{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-brand-400{--tw-ring-opacity: 1;--tw-ring-color: rgb(146 212 68 / var(--tw-ring-opacity, 1))}.ring-brand-500{--tw-ring-opacity: 1;--tw-ring-color: rgb(107 166 38 / var(--tw-ring-opacity, 1))}.ring-brand-500\/30{--tw-ring-color: rgb(107 166 38 / .3)}.ring-brand-500\/40{--tw-ring-color: rgb(107 166 38 / .4)}.ring-neutral-600{--tw-ring-opacity: 1;--tw-ring-color: rgb(82 82 82 / var(--tw-ring-opacity, 1))}.ring-white{--tw-ring-opacity: 1;--tw-ring-color: rgb(255 255 255 / var(--tw-ring-opacity, 1))}.ring-white\/50{--tw-ring-color: rgb(255 255 255 / .5)}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.grayscale{--tw-grayscale: grayscale(100%);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur{--tw-backdrop-blur: blur(8px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-xl{--tw-backdrop-blur: blur(24px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\[filter\,box-shadow\]{transition-property:filter,box-shadow;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\[width\]{transition-property:width;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-shadow{transition-property:box-shadow;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}.duration-500{transition-duration:.5s}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.will-change-transform{will-change:transform}.\[scrollbar-width\:none\]{scrollbar-width:none}html{scroll-behavior:smooth}.marquee-viewport{-webkit-mask-image:linear-gradient(to right,transparent,black 6%,black 94%,transparent);mask-image:linear-gradient(to right,transparent,black 6%,black 94%,transparent)}.page-texture{background-color:#f6f5f0;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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.13 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");background-size:180px 180px}.dark .page-texture{background-color:#0a0b07;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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.14 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")}.kf-page{--kf-pagebg: linear-gradient(120deg, #eef0ea 0%, #f6f8f3 45%, #fbfcf9 100%);--kf-card: #ffffff;--kf-cardbrd: #e4e8dc;--kf-text: #23271d;--kf-text2: #2a2e24;--kf-muted: #6c7360;--kf-label: #5f6650;--kf-field: #fafcf6;--kf-fieldbrd: #dde2d3;--kf-fieldicon: #a7ad9d;--kf-accent: #a4d417;--kf-accent2: #4f7a00;--kf-accentsoft: #f2f8df;--kf-pill: #ffffff;--kf-pillbrd: #dfe4d6;--kf-shadow: 0 24px 60px rgba(60, 70, 40, .08);--kf-shadow2: 0 16px 40px rgba(60, 70, 40, .06);--kf-divider: #e8ecdf;--kf-topo: #d7dccd;--kf-pkgbg: #f4fbe4;--kf-pkgbrd: #cfe89a;--kf-btntext: #1f2417;--kf-scrim: linear-gradient(90deg, rgba(244, 246, 241, .35) 0%, rgba(244, 246, 241, .55) 55%, rgba(246, 248, 243, 1) 100%)}.dark .kf-page{--kf-pagebg: linear-gradient(120deg, #181b0f 0%, #111409 45%, #0a0c06 100%);--kf-card: #14170e;--kf-cardbrd: rgba(168, 225, 12, .16);--kf-text: #f3f6ea;--kf-text2: #e8ece0;--kf-muted: #9aa38c;--kf-label: #8f987f;--kf-field: rgba(0, 0, 0, .35);--kf-fieldbrd: #2c3323;--kf-fieldicon: #5f6852;--kf-accent: #a8e10c;--kf-accent2: #b6e619;--kf-accentsoft: rgba(168, 225, 12, .1);--kf-pill: #14170e;--kf-pillbrd: rgba(168, 225, 12, .28);--kf-shadow: 0 24px 60px rgba(0, 0, 0, .55);--kf-shadow2: 0 16px 40px rgba(0, 0, 0, .45);--kf-divider: rgba(168, 225, 12, .15);--kf-pkgbg: rgba(168, 225, 12, .08);--kf-pkgbrd: rgba(168, 225, 12, .4);--kf-btntext: #0f1208}.kontakt-sektion{background-image:url(/assets/bg-light-CBAG2tPV.webp);background-size:cover;background-position:center}.dark .kontakt-sektion{background-image:url(/assets/bg-dark-B4R1klEI.webp)}.kf-page input::-moz-placeholder,.kf-page textarea::-moz-placeholder{color:var(--kf-fieldicon)}.kf-page input::placeholder,.kf-page textarea::placeholder{color:var(--kf-fieldicon)}.kf-page input:focus,.kf-page textarea:focus{border-color:var(--kf-accent)!important;box-shadow:0 0 0 3px #a4d41733}.grain-band{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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.13 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");background-size:180px 180px}.dark .grain-band{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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.14 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")}html.hifi-cursor-on,html.hifi-cursor-on *{cursor:none!important}html.hifi-cursor-on :is(input,textarea,[contenteditable=true]){cursor:auto!important}.hifi-cursor{position:fixed;top:0;right:0;bottom:0;left:0;pointer-events:none;z-index:99999;opacity:1;transition:opacity .2s ease}.hifi-cursor[data-hidden=true]{opacity:0}.hifi-cursor__core{position:fixed;top:0;left:0;width:10px;height:10px;margin:-5px 0 0 -5px;border-radius:9999px;background:#7fd44a;box-shadow:0 0 0 1.5px #ffffffe6,0 0 10px #7fd44abf;transition:width .18s ease,height .18s ease,margin .18s ease,background-color .18s ease,opacity .15s ease}.hifi-cursor__orbit{position:fixed;top:0;left:0;opacity:0;transition:opacity .18s ease}.hifi-cursor__ring{position:absolute;width:38px;height:15px;margin:-7.5px 0 0 -19px;border:1px solid rgba(139,234,60,.85);border-radius:50%;transform:rotate(-24deg) scale(.6);transition:transform .22s ease}.hifi-cursor__sat{position:absolute;width:5px;height:5px;margin:-2.5px 0 0 -2.5px;border-radius:9999px;background:#eaffdb;box-shadow:0 0 6px #8bea3ce6}.hifi-cursor[data-state=hover] .hifi-cursor__orbit{opacity:1}.hifi-cursor[data-state=hover] .hifi-cursor__core{width:16px;height:16px;margin:-8px 0 0 -8px;background:#8bea3c;box-shadow:0 0 0 1.5px #fffffff2,0 0 12px #8bea3cd9}.hifi-cursor[data-state=hover] .hifi-cursor__ring{transform:rotate(-24deg) scale(1.45)}.hifi-cursor[data-state=text] .hifi-cursor__core,.hifi-cursor[data-state=text] .hifi-cursor__orbit{opacity:0}.hifi-cursor[data-down=true] .hifi-cursor__core{width:20px;height:20px;margin:-10px 0 0 -10px}.hifi-cursor__pulse{position:fixed;top:0;left:0;width:12px;height:12px;margin:-6px 0 0 -6px;border-radius:9999px;border:1.5px solid rgba(139,234,60,.9);opacity:0}.hifi-cursor__pulse.is-live{animation:hifi-cursor-pulse .45s ease-out forwards}@keyframes hifi-cursor-pulse{0%{opacity:.9;transform:scale(1)}to{opacity:0;transform:scale(3.2)}}.rte-content ul{list-style:disc;padding-left:1.5rem}.rte-content ol{list-style:decimal;padding-left:1.5rem}.rte-content a{color:#3b82f6;text-decoration:underline}.rte-content p{margin:.25rem 0}.rte-content h2{font-size:1.125rem;font-weight:700;margin:.75rem 0 .25rem}.rte-content code{font-family:ui-monospace,monospace;background:#7d7d7d26;border-radius:.25rem;padding:.1rem .3rem;font-size:.85em}.legal-content h2{margin:2rem 0 .5rem;font-weight:600;color:#171717}.dark .legal-content h2{color:#fff}.legal-content h2:first-child{margin-top:0}.legal-content p{margin:.5rem 0}.legal-content ul{list-style:disc;padding-left:1.25rem;margin:.5rem 0}.legal-content li{margin:.25rem 0}.legal-content a{color:#6ba626;text-decoration:underline}.legal-content code{font-family:ui-monospace,monospace;background:#7d7d7d26;border-radius:.25rem;padding:.1rem .3rem;font-size:.85em}.file\:mr-3::file-selector-button{margin-right:.75rem}.file\:rounded-md::file-selector-button{border-radius:.375rem}.file\:border-0::file-selector-button{border-width:0px}.file\:bg-brand-500::file-selector-button{--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.file\:px-3::file-selector-button{padding-left:.75rem;padding-right:.75rem}.file\:py-2::file-selector-button{padding-top:.5rem;padding-bottom:.5rem}.file\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\:font-semibold::file-selector-button{font-weight:600}.file\:text-white::file-selector-button{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.last\:border-b-0:last-child{border-bottom-width:0px}.hover\:-translate-y-0\.5:hover{--tw-translate-y: -.125rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:scale-105:hover{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:border-\[var\(--kf-accent\)\]:hover{border-color:var(--kf-accent)}.hover\:border-brand-500:hover{--tw-border-opacity: 1;border-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.hover\:border-neutral-400:hover{--tw-border-opacity: 1;border-color:rgb(163 163 163 / var(--tw-border-opacity, 1))}.hover\:bg-\[var\(--kf-accentsoft\)\]:hover{background-color:var(--kf-accentsoft)}.hover\:bg-amber-100:hover{--tw-bg-opacity: 1;background-color:rgb(254 243 199 / var(--tw-bg-opacity, 1))}.hover\:bg-brand-400:hover{--tw-bg-opacity: 1;background-color:rgb(146 212 68 / var(--tw-bg-opacity, 1))}.hover\:bg-brand-50:hover{--tw-bg-opacity: 1;background-color:rgb(245 251 238 / var(--tw-bg-opacity, 1))}.hover\:bg-brand-600:hover{--tw-bg-opacity: 1;background-color:rgb(88 137 31 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-100:hover{--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 229 229 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-50:hover{--tw-bg-opacity: 1;background-color:rgb(250 250 250 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-800:hover{--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.hover\:bg-red-50:hover{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.hover\:bg-red-700:hover{--tw-bg-opacity: 1;background-color:rgb(185 28 28 / var(--tw-bg-opacity, 1))}.hover\:bg-white\/10:hover{background-color:#ffffff1a}.hover\:bg-white\/15:hover{background-color:#ffffff26}.hover\:bg-white\/20:hover{background-color:#fff3}.hover\:text-brand-500:hover{--tw-text-opacity: 1;color:rgb(107 166 38 / var(--tw-text-opacity, 1))}.hover\:text-brand-600:hover{--tw-text-opacity: 1;color:rgb(88 137 31 / var(--tw-text-opacity, 1))}.hover\:text-neutral-600:hover{--tw-text-opacity: 1;color:rgb(82 82 82 / var(--tw-text-opacity, 1))}.hover\:text-neutral-700:hover{--tw-text-opacity: 1;color:rgb(64 64 64 / var(--tw-text-opacity, 1))}.hover\:text-red-600:hover{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.hover\:text-white:hover{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:opacity-80:hover{opacity:.8}.hover\:shadow-lg:hover{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.hover\:shadow-md:hover{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.hover\:brightness-110:hover{--tw-brightness: brightness(1.1);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.hover\:grayscale-0:hover{--tw-grayscale: grayscale(0);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.hover\:file\:bg-brand-600::file-selector-button:hover{--tw-bg-opacity: 1;background-color:rgb(88 137 31 / var(--tw-bg-opacity, 1))}.focus\:border-brand-500:focus{--tw-border-opacity: 1;border-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-brand-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(107 166 38 / var(--tw-ring-opacity, 1))}.active\:cursor-grabbing:active{cursor:grabbing}.disabled\:opacity-40:disabled{opacity:.4}.disabled\:opacity-50:disabled{opacity:.5}.disabled\:opacity-60:disabled{opacity:.6}.group:hover .group-hover\:scale-105{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:from-black\/95{--tw-gradient-from: rgb(0 0 0 / .95) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.peer:checked~.peer-checked\:translate-x-5{--tw-translate-x: 1.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.peer:checked~.peer-checked\:bg-brand-500{--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.peer:disabled~.peer-disabled\:opacity-60{opacity:.6}.dark\:block:is(.dark *){display:block}.dark\:hidden:is(.dark *){display:none}.dark\:divide-neutral-800:is(.dark *)>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(38 38 38 / var(--tw-divide-opacity, 1))}.dark\:border-amber-700:is(.dark *){--tw-border-opacity: 1;border-color:rgb(180 83 9 / var(--tw-border-opacity, 1))}.dark\:border-amber-900:is(.dark *){--tw-border-opacity: 1;border-color:rgb(120 53 15 / var(--tw-border-opacity, 1))}.dark\:border-green-900:is(.dark *){--tw-border-opacity: 1;border-color:rgb(20 83 45 / var(--tw-border-opacity, 1))}.dark\:border-neutral-700:is(.dark *){--tw-border-opacity: 1;border-color:rgb(64 64 64 / var(--tw-border-opacity, 1))}.dark\:border-neutral-800:is(.dark *){--tw-border-opacity: 1;border-color:rgb(38 38 38 / var(--tw-border-opacity, 1))}.dark\:border-red-900:is(.dark *){--tw-border-opacity: 1;border-color:rgb(127 29 29 / var(--tw-border-opacity, 1))}.dark\:border-t-brand-500:is(.dark *){--tw-border-opacity: 1;border-top-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.dark\:bg-amber-900\/20:is(.dark *){background-color:#78350f33}.dark\:bg-amber-900\/30:is(.dark *){background-color:#78350f4d}.dark\:bg-amber-900\/40:is(.dark *){background-color:#78350f66}.dark\:bg-amber-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(69 26 3 / var(--tw-bg-opacity, 1))}.dark\:bg-amber-950\/40:is(.dark *){background-color:#451a0366}.dark\:bg-brand-500:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.dark\:bg-brand-900\/20:is(.dark *){background-color:#304b1133}.dark\:bg-brand-900\/40:is(.dark *){background-color:#304b1166}.dark\:bg-green-900\/20:is(.dark *){background-color:#14532d33}.dark\:bg-green-900\/40:is(.dark *){background-color:#14532d66}.dark\:bg-green-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(5 46 22 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-100:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-600:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(82 82 82 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-700:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(64 64 64 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-800:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-800\/50:is(.dark *){background-color:#26262680}.dark\:bg-neutral-900:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(23 23 23 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-900\/40:is(.dark *){background-color:#17171766}.dark\:bg-neutral-900\/95:is(.dark *){background-color:#171717f2}.dark\:bg-neutral-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(10 10 10 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-950\/95:is(.dark *){background-color:#0a0a0af2}.dark\:bg-red-900\/10:is(.dark *){background-color:#7f1d1d1a}.dark\:bg-red-900\/20:is(.dark *){background-color:#7f1d1d33}.dark\:bg-red-900\/40:is(.dark *){background-color:#7f1d1d66}.dark\:bg-red-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(69 10 10 / var(--tw-bg-opacity, 1))}.dark\:bg-slate-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(2 6 23 / var(--tw-bg-opacity, 1))}.dark\:bg-white\/10:is(.dark *){background-color:#ffffff1a}.dark\:text-amber-200:is(.dark *){--tw-text-opacity: 1;color:rgb(253 230 138 / var(--tw-text-opacity, 1))}.dark\:text-amber-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 211 77 / var(--tw-text-opacity, 1))}.dark\:text-amber-400:is(.dark *){--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.dark\:text-brand-200:is(.dark *){--tw-text-opacity: 1;color:rgb(211 238 180 / var(--tw-text-opacity, 1))}.dark\:text-brand-300:is(.dark *){--tw-text-opacity: 1;color:rgb(182 227 130 / var(--tw-text-opacity, 1))}.dark\:text-brand-400:is(.dark *){--tw-text-opacity: 1;color:rgb(146 212 68 / var(--tw-text-opacity, 1))}.dark\:text-brand-400\/10:is(.dark *){color:#92d4441a}.dark\:text-green-200:is(.dark *){--tw-text-opacity: 1;color:rgb(187 247 208 / var(--tw-text-opacity, 1))}.dark\:text-green-300:is(.dark *){--tw-text-opacity: 1;color:rgb(134 239 172 / var(--tw-text-opacity, 1))}.dark\:text-green-400:is(.dark *){--tw-text-opacity: 1;color:rgb(74 222 128 / var(--tw-text-opacity, 1))}.dark\:text-neutral-100:is(.dark *){--tw-text-opacity: 1;color:rgb(245 245 245 / var(--tw-text-opacity, 1))}.dark\:text-neutral-200:is(.dark *){--tw-text-opacity: 1;color:rgb(229 229 229 / var(--tw-text-opacity, 1))}.dark\:text-neutral-300:is(.dark *){--tw-text-opacity: 1;color:rgb(212 212 212 / var(--tw-text-opacity, 1))}.dark\:text-neutral-400:is(.dark *){--tw-text-opacity: 1;color:rgb(163 163 163 / var(--tw-text-opacity, 1))}.dark\:text-neutral-500:is(.dark *){--tw-text-opacity: 1;color:rgb(115 115 115 / var(--tw-text-opacity, 1))}.dark\:text-neutral-600:is(.dark *){--tw-text-opacity: 1;color:rgb(82 82 82 / var(--tw-text-opacity, 1))}.dark\:text-neutral-900:is(.dark *){--tw-text-opacity: 1;color:rgb(23 23 23 / var(--tw-text-opacity, 1))}.dark\:text-red-200:is(.dark *){--tw-text-opacity: 1;color:rgb(254 202 202 / var(--tw-text-opacity, 1))}.dark\:text-red-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 165 165 / var(--tw-text-opacity, 1))}.dark\:text-red-400:is(.dark *){--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.dark\:text-slate-100:is(.dark *){--tw-text-opacity: 1;color:rgb(241 245 249 / var(--tw-text-opacity, 1))}.dark\:text-white:is(.dark *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.dark\:shadow-black\/40:is(.dark *){--tw-shadow-color: rgb(0 0 0 / .4);--tw-shadow: var(--tw-shadow-colored)}.dark\:ring-neutral-900:is(.dark *){--tw-ring-opacity: 1;--tw-ring-color: rgb(23 23 23 / var(--tw-ring-opacity, 1))}.dark\:hover\:border-neutral-600:hover:is(.dark *){--tw-border-opacity: 1;border-color:rgb(82 82 82 / var(--tw-border-opacity, 1))}.dark\:hover\:bg-brand-900\/20:hover:is(.dark *){background-color:#304b1133}.dark\:hover\:bg-neutral-700:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(64 64 64 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-neutral-800:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-neutral-800\/40:hover:is(.dark *){background-color:#26262666}.dark\:hover\:bg-neutral-800\/50:hover:is(.dark *){background-color:#26262680}.dark\:hover\:bg-red-900\/20:hover:is(.dark *){background-color:#7f1d1d33}.dark\:hover\:bg-red-900\/30:hover:is(.dark *){background-color:#7f1d1d4d}.dark\:hover\:text-brand-400:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(146 212 68 / var(--tw-text-opacity, 1))}.dark\:hover\:text-neutral-200:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(229 229 229 / var(--tw-text-opacity, 1))}.dark\:hover\:text-neutral-300:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(212 212 212 / var(--tw-text-opacity, 1))}@media (min-width: 640px){.sm\:left-4{left:1rem}.sm\:left-8{left:2rem}.sm\:right-4{right:1rem}.sm\:top-\[65px\]{top:65px}.sm\:col-span-2{grid-column:span 2 / span 2}.sm\:-mx-6{margin-left:-1.5rem;margin-right:-1.5rem}.sm\:-mt-\[97px\]{margin-top:-97px}.sm\:block{display:block}.sm\:inline{display:inline}.sm\:hidden{display:none}.sm\:h-16{height:4rem}.sm\:h-20{height:5rem}.sm\:h-96{height:24rem}.sm\:min-h-\[85vh\]{min-height:85vh}.sm\:w-64{width:16rem}.sm\:w-72{width:18rem}.sm\:w-auto{width:auto}.sm\:flex-none{flex:none}.sm\:shrink-0{flex-shrink:0}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.sm\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.sm\:grid-cols-8{grid-template-columns:repeat(8,minmax(0,1fr))}.sm\:grid-cols-\[10rem_1fr\]{grid-template-columns:10rem 1fr}.sm\:grid-cols-\[16rem_1fr\]{grid-template-columns:16rem 1fr}.sm\:grid-cols-\[1fr_120px\]{grid-template-columns:1fr 120px}.sm\:grid-cols-\[1fr_120px_1fr\]{grid-template-columns:1fr 120px 1fr}.sm\:flex-row{flex-direction:row}.sm\:items-start{align-items:flex-start}.sm\:items-center{align-items:center}.sm\:justify-between{justify-content:space-between}.sm\:p-10{padding:2.5rem}.sm\:p-5{padding:1.25rem}.sm\:p-6{padding:1.5rem}.sm\:px-10{padding-left:2.5rem;padding-right:2.5rem}.sm\:px-6{padding-left:1.5rem;padding-right:1.5rem}.sm\:px-8{padding-left:2rem;padding-right:2rem}.sm\:py-14{padding-top:3.5rem;padding-bottom:3.5rem}.sm\:py-\[34px\]{padding-top:34px;padding-bottom:34px}.sm\:pb-14{padding-bottom:3.5rem}.sm\:pl-11{padding-left:2.75rem}.sm\:pl-8{padding-left:2rem}.sm\:pt-1{padding-top:.25rem}.sm\:pt-14{padding-top:3.5rem}.sm\:text-3xl{font-size:1.875rem;line-height:2.25rem}.sm\:text-4xl{font-size:2.25rem;line-height:2.5rem}.sm\:text-5xl{font-size:3rem;line-height:1}.sm\:text-\[46px\]{font-size:46px}.sm\:text-lg{font-size:1.125rem;line-height:1.75rem}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}@media (min-width: 641px){.min-\[641px\]\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.min-\[641px\]\:border-b-0{border-bottom-width:0px}.min-\[641px\]\:border-r{border-right-width:1px}.min-\[641px\]\:last\:border-r-0:last-child{border-right-width:0px}}@media (min-width: 768px){.md\:order-1{order:1}.md\:order-2{order:2}.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.md\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (min-width: 901px){.min-\[901px\]\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (min-width: 981px){.min-\[981px\]\:grid-cols-\[minmax\(0\,1\.35fr\)_minmax\(320px\,1fr\)\]{grid-template-columns:minmax(0,1.35fr) minmax(320px,1fr)}}@media (min-width: 1024px){.lg\:col-span-2{grid-column:span 2 / span 2}.lg\:flex{display:flex}.lg\:inline-flex{display:inline-flex}.lg\:w-80{width:20rem}.lg\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:text-\[60px\]{font-size:60px}}.\[\&\:\:-webkit-scrollbar\]\:hidden::-webkit-scrollbar{display:none} diff --git a/hifi/assets/index-DJmr5-XD.css b/hifi/assets/index-DJmr5-XD.css new file mode 100644 index 0000000..9e54e19 --- /dev/null +++ b/hifi/assets/index-DJmr5-XD.css @@ -0,0 +1 @@ +@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/barlow-vietnamese-400-normal-Dpl4UHAZ.woff2) format("woff2"),url(/assets/barlow-vietnamese-400-normal-BFeobeCK.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/barlow-latin-ext-400-normal-HxX4XjxC.woff2) format("woff2"),url(/assets/barlow-latin-ext-400-normal-CvBsJvxq.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/barlow-latin-400-normal-qiz4-Cze.woff2) format("woff2"),url(/assets/barlow-latin-400-normal-fsAxiSwU.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-vietnamese-500-normal-zTViEIzf.woff2) format("woff2"),url(/assets/barlow-vietnamese-500-normal-GNfB7rCE.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-latin-ext-500-normal-DOaysfXq.woff2) format("woff2"),url(/assets/barlow-latin-ext-500-normal-CJPcKP2Q.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-latin-500-normal-BPAOfeC8.woff2) format("woff2"),url(/assets/barlow-latin-500-normal-C1h8hMer.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-vietnamese-600-normal-DcjprdFV.woff2) format("woff2"),url(/assets/barlow-vietnamese-600-normal-CA_GiK2e.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-latin-ext-600-normal-B8NK_A3D.woff2) format("woff2"),url(/assets/barlow-latin-ext-600-normal-DMVRjfRT.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-latin-600-normal-DILqtrty.woff2) format("woff2"),url(/assets/barlow-latin-600-normal-CNwfPWQD.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:700;src:url(/assets/barlow-vietnamese-700-normal-D6euyNzi.woff2) format("woff2"),url(/assets/barlow-vietnamese-700-normal-4Jt4k04K.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:700;src:url(/assets/barlow-latin-ext-700-normal-BLuWmldJ.woff2) format("woff2"),url(/assets/barlow-latin-ext-700-normal-CctuGmmz.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow;font-style:normal;font-display:swap;font-weight:700;src:url(/assets/barlow-latin-700-normal-A9pxMQ4z.woff2) format("woff2"),url(/assets/barlow-latin-700-normal-__SGTsZ1.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-condensed-vietnamese-500-normal-DjeaNLFD.woff2) format("woff2"),url(/assets/barlow-condensed-vietnamese-500-normal-CsrJDWc5.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-condensed-latin-ext-500-normal-yA5ONLQ9.woff2) format("woff2"),url(/assets/barlow-condensed-latin-ext-500-normal-B1RE8WP7.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:500;src:url(/assets/barlow-condensed-latin-500-normal-BgYH2mbd.woff2) format("woff2"),url(/assets/barlow-condensed-latin-500-normal-HIEiP5Ov.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-condensed-vietnamese-600-normal-A5AYRdjN.woff2) format("woff2"),url(/assets/barlow-condensed-vietnamese-600-normal-CNlPk46_.woff) format("woff");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-condensed-latin-ext-600-normal-18ESti3H.woff2) format("woff2"),url(/assets/barlow-condensed-latin-ext-600-normal-Clv9cIcR.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Barlow Condensed;font-style:normal;font-display:swap;font-weight:600;src:url(/assets/barlow-condensed-latin-600-normal-DepVgxBB.woff2) format("woff2"),url(/assets/barlow-condensed-latin-600-normal-BFJEwTuo.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Michroma;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/michroma-latin-ext-400-normal-BeYM1uOO.woff2) format("woff2"),url(/assets/michroma-latin-ext-400-normal-DlRaauac.woff) format("woff");unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Michroma;font-style:normal;font-display:swap;font-weight:400;src:url(/assets/michroma-latin-400-normal-4gS0VCia.woff2) format("woff2"),url(/assets/michroma-latin-400-normal-C7Pn7qca.woff) format("woff");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:var(--site-font, ui-sans-serif, system-ui, sans-serif);font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.\!container{width:100%!important}.container{width:100%}@media (min-width: 640px){.\!container{max-width:640px!important}.container{max-width:640px}}@media (min-width: 768px){.\!container{max-width:768px!important}.container{max-width:768px}}@media (min-width: 1024px){.\!container{max-width:1024px!important}.container{max-width:1024px}}@media (min-width: 1280px){.\!container{max-width:1280px!important}.container{max-width:1280px}}@media (min-width: 1536px){.\!container{max-width:1536px!important}.container{max-width:1536px}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.\!visible{visibility:visible!important}.visible{visibility:visible}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.inset-x-0{left:0;right:0}.inset-y-0{top:0;bottom:0}.-bottom-5{bottom:-1.25rem}.-left-1\/3{left:-33.333333%}.-right-1{right:-.25rem}.-right-1\.5{right:-.375rem}.-right-\[60px\]{right:-60px}.-top-1{top:-.25rem}.-top-1\.5{top:-.375rem}.-top-3{top:-.75rem}.-top-\[60px\]{top:-60px}.bottom-0{bottom:0}.bottom-4{bottom:1rem}.left-0{left:0}.left-1{left:.25rem}.left-1\/2{left:50%}.left-2{left:.5rem}.left-3\.5{left:.875rem}.left-5{left:1.25rem}.left-6{left:1.5rem}.left-\[14px\]{left:14px}.right-0{right:0}.right-2{right:.5rem}.right-4{right:1rem}.top-0{top:0}.top-1{top:.25rem}.top-1\/2{top:50%}.top-2{top:.5rem}.top-3\.5{top:.875rem}.top-4{top:1rem}.top-8{top:2rem}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\[100\]{z-index:100}.z-\[200\]{z-index:200}.z-\[300\]{z-index:300}.z-\[400\]{z-index:400}.z-\[60\]{z-index:60}.order-1{order:1}.order-2{order:2}.col-span-full{grid-column:1 / -1}.-mx-4{margin-left:-1rem;margin-right:-1rem}.mx-1{margin-left:.25rem;margin-right:.25rem}.mx-auto{margin-left:auto;margin-right:auto}.-mt-\[89px\]{margin-top:-89px}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-10{margin-bottom:2.5rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-3\.5{margin-bottom:.875rem}.mb-4{margin-bottom:1rem}.mb-5{margin-bottom:1.25rem}.mb-6{margin-bottom:1.5rem}.mb-7{margin-bottom:1.75rem}.mb-8{margin-bottom:2rem}.ml-1{margin-left:.25rem}.ml-2{margin-left:.5rem}.ml-auto{margin-left:auto}.mr-3{margin-right:.75rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-10{margin-top:2.5rem}.mt-12{margin-top:3rem}.mt-2{margin-top:.5rem}.mt-2\.5{margin-top:.625rem}.mt-3{margin-top:.75rem}.mt-3\.5{margin-top:.875rem}.mt-4{margin-top:1rem}.mt-5{margin-top:1.25rem}.mt-6{margin-top:1.5rem}.mt-7{margin-top:1.75rem}.mt-8{margin-top:2rem}.mt-auto{margin-top:auto}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.line-clamp-6{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:6}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.contents{display:contents}.\!hidden{display:none!important}.hidden{display:none}.aspect-\[4\/3\]{aspect-ratio:4/3}.aspect-square{aspect-ratio:1 / 1}.aspect-video{aspect-ratio:16 / 9}.h-0\.5{height:.125rem}.h-1\.5{height:.375rem}.h-10{height:2.5rem}.h-11{height:2.75rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-24{height:6rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-4{height:1rem}.h-48{height:12rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-7{height:1.75rem}.h-8{height:2rem}.h-80{height:20rem}.h-9{height:2.25rem}.h-\[17px\]{height:17px}.h-\[18px\]{height:18px}.h-\[190px\]{height:190px}.h-\[210px\]{height:210px}.h-\[22px\]{height:22px}.h-\[46px\]{height:46px}.h-fit{height:-moz-fit-content;height:fit-content}.h-full{height:100%}.h-px{height:1px}.h-svh{height:100svh}.max-h-64{max-height:16rem}.max-h-\[85vh\]{max-height:85vh}.min-h-\[10rem\]{min-height:10rem}.min-h-\[560px\]{min-height:560px}.min-h-\[60vh\]{min-height:60vh}.min-h-\[70vh\]{min-height:70vh}.min-h-full{min-height:100%}.min-h-screen{min-height:100vh}.w-1\.5{width:.375rem}.w-1\/3{width:33.333333%}.w-10{width:2.5rem}.w-11{width:2.75rem}.w-12{width:3rem}.w-16{width:4rem}.w-24{width:6rem}.w-28{width:7rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-4{width:1rem}.w-44{width:11rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-60{width:15rem}.w-64{width:16rem}.w-7{width:1.75rem}.w-8{width:2rem}.w-9{width:2.25rem}.w-\[17px\]{width:17px}.w-\[18px\]{width:18px}.w-\[190px\]{width:190px}.w-\[22px\]{width:22px}.w-\[46px\]{width:46px}.w-\[min\(92vw\,380px\)\]{width:min(92vw,380px)}.w-auto{width:auto}.w-full{width:100%}.w-max{width:-moz-max-content;width:max-content}.w-px{width:1px}.min-w-0{min-width:0px}.min-w-\[220px\]{min-width:220px}.min-w-\[640px\]{min-width:640px}.min-w-\[90px\]{min-width:90px}.min-w-\[9rem\]{min-width:9rem}.max-w-2xl{max-width:42rem}.max-w-3xl{max-width:48rem}.max-w-4xl{max-width:56rem}.max-w-6xl{max-width:72rem}.max-w-\[1280px\]{max-width:1280px}.max-w-\[160px\]{max-width:160px}.max-w-\[1880px\]{max-width:1880px}.max-w-\[520px\]{max-width:520px}.max-w-\[85\%\]{max-width:85%}.max-w-\[8rem\]{max-width:8rem}.max-w-\[calc\(100\%-16px\)\]{max-width:calc(100% - 16px)}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-sm{max-width:24rem}.max-w-xl{max-width:36rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.flex-shrink-0,.shrink-0{flex-shrink:0}.origin-left{transform-origin:left}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-12{--tw-rotate: 12deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate: 180deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-grab{cursor:grab}.cursor-grabbing{cursor:grabbing}.cursor-pointer{cursor:pointer}.touch-none{touch-action:none}.touch-pan-y{--tw-pan-y: pan-y;touch-action:var(--tw-pan-x) var(--tw-pan-y) var(--tw-pinch-zoom)}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-y{resize:vertical}.snap-x{scroll-snap-type:x var(--tw-scroll-snap-strictness)}.snap-mandatory{--tw-scroll-snap-strictness: mandatory}.snap-start{scroll-snap-align:start}.snap-center{scroll-snap-align:center}.scroll-mt-20{scroll-margin-top:5rem}.scroll-mt-4{scroll-margin-top:1rem}.list-decimal{list-style-type:decimal}.list-disc{list-style-type:disc}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.grid-cols-\[1fr_auto_1fr\]{grid-template-columns:1fr auto 1fr}.grid-cols-\[auto_1fr\]{grid-template-columns:auto 1fr}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.items-baseline{align-items:baseline}.items-stretch{align-items:stretch}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-10{gap:2.5rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-5{gap:1.25rem}.gap-6{gap:1.5rem}.gap-8{gap:2rem}.gap-\[18px\]{gap:18px}.gap-x-2{-moz-column-gap:.5rem;column-gap:.5rem}.gap-x-3{-moz-column-gap:.75rem;column-gap:.75rem}.gap-x-5{-moz-column-gap:1.25rem;column-gap:1.25rem}.gap-x-6{-moz-column-gap:1.5rem;column-gap:1.5rem}.gap-x-8{-moz-column-gap:2rem;column-gap:2rem}.gap-x-\[18px\]{-moz-column-gap:18px;column-gap:18px}.gap-y-1{row-gap:.25rem}.gap-y-2{row-gap:.5rem}.gap-y-3{row-gap:.75rem}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-16>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(4rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(4rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.space-y-5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.25rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse: 0;border-top-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(1px * var(--tw-divide-y-reverse))}.divide-neutral-100>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(245 245 245 / var(--tw-divide-opacity, 1))}.divide-neutral-200>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(229 229 229 / var(--tw-divide-opacity, 1))}.justify-self-start{justify-self:start}.justify-self-end{justify-self:end}.justify-self-center{justify-self:center}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-line{white-space:pre-line}.whitespace-pre-wrap{white-space:pre-wrap}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-\[10px\]{border-radius:10px}.rounded-\[18px\]{border-radius:18px}.rounded-\[3px\]{border-radius:3px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-xl{border-radius:.75rem}.rounded-b-xl{border-bottom-right-radius:.75rem;border-bottom-left-radius:.75rem}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-0{border-width:0px}.border-4{border-width:4px}.border-\[1\.5px\]{border-width:1.5px}.border-y{border-top-width:1px;border-bottom-width:1px}.border-b{border-bottom-width:1px}.border-r{border-right-width:1px}.border-t{border-top-width:1px}.border-dashed{border-style:dashed}.border-amber-200{--tw-border-opacity: 1;border-color:rgb(253 230 138 / var(--tw-border-opacity, 1))}.border-amber-300{--tw-border-opacity: 1;border-color:rgb(252 211 77 / var(--tw-border-opacity, 1))}.border-brand-500{--tw-border-opacity: 1;border-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.border-green-200{--tw-border-opacity: 1;border-color:rgb(187 247 208 / var(--tw-border-opacity, 1))}.border-neutral-100{--tw-border-opacity: 1;border-color:rgb(245 245 245 / var(--tw-border-opacity, 1))}.border-neutral-200{--tw-border-opacity: 1;border-color:rgb(229 229 229 / var(--tw-border-opacity, 1))}.border-neutral-300{--tw-border-opacity: 1;border-color:rgb(212 212 212 / var(--tw-border-opacity, 1))}.border-neutral-700{--tw-border-opacity: 1;border-color:rgb(64 64 64 / var(--tw-border-opacity, 1))}.border-neutral-800{--tw-border-opacity: 1;border-color:rgb(38 38 38 / var(--tw-border-opacity, 1))}.border-red-200{--tw-border-opacity: 1;border-color:rgb(254 202 202 / var(--tw-border-opacity, 1))}.border-red-300{--tw-border-opacity: 1;border-color:rgb(252 165 165 / var(--tw-border-opacity, 1))}.border-transparent{border-color:transparent}.border-white\/10{border-color:#ffffff1a}.border-white\/15{border-color:#ffffff26}.border-white\/30{border-color:#ffffff4d}.border-t-brand-500{--tw-border-opacity: 1;border-top-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.bg-amber-100{--tw-bg-opacity: 1;background-color:rgb(254 243 199 / var(--tw-bg-opacity, 1))}.bg-amber-400{--tw-bg-opacity: 1;background-color:rgb(251 191 36 / var(--tw-bg-opacity, 1))}.bg-amber-50{--tw-bg-opacity: 1;background-color:rgb(255 251 235 / var(--tw-bg-opacity, 1))}.bg-amber-500{--tw-bg-opacity: 1;background-color:rgb(245 158 11 / var(--tw-bg-opacity, 1))}.bg-black\/50{background-color:#00000080}.bg-black\/55{background-color:#0000008c}.bg-black\/60{background-color:#0009}.bg-black\/70{background-color:#000000b3}.bg-black\/90{background-color:#000000e6}.bg-brand-100{--tw-bg-opacity: 1;background-color:rgb(233 246 218 / var(--tw-bg-opacity, 1))}.bg-brand-400{--tw-bg-opacity: 1;background-color:rgb(146 212 68 / var(--tw-bg-opacity, 1))}.bg-brand-50{--tw-bg-opacity: 1;background-color:rgb(245 251 238 / var(--tw-bg-opacity, 1))}.bg-brand-500{--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.bg-brand-500\/10{background-color:#6ba6261a}.bg-brand-500\/60{background-color:#6ba62699}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231 / var(--tw-bg-opacity, 1))}.bg-green-50{--tw-bg-opacity: 1;background-color:rgb(240 253 244 / var(--tw-bg-opacity, 1))}.bg-green-500{--tw-bg-opacity: 1;background-color:rgb(34 197 94 / var(--tw-bg-opacity, 1))}.bg-neutral-100{--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.bg-neutral-200{--tw-bg-opacity: 1;background-color:rgb(229 229 229 / var(--tw-bg-opacity, 1))}.bg-neutral-300{--tw-bg-opacity: 1;background-color:rgb(212 212 212 / var(--tw-bg-opacity, 1))}.bg-neutral-400{--tw-bg-opacity: 1;background-color:rgb(163 163 163 / var(--tw-bg-opacity, 1))}.bg-neutral-50{--tw-bg-opacity: 1;background-color:rgb(250 250 250 / var(--tw-bg-opacity, 1))}.bg-neutral-800{--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.bg-neutral-900{--tw-bg-opacity: 1;background-color:rgb(23 23 23 / var(--tw-bg-opacity, 1))}.bg-neutral-900\/10{background-color:#1717171a}.bg-neutral-900\/85{background-color:#171717d9}.bg-neutral-950{--tw-bg-opacity: 1;background-color:rgb(10 10 10 / var(--tw-bg-opacity, 1))}.bg-neutral-950\/90{background-color:#0a0a0ae6}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226 / var(--tw-bg-opacity, 1))}.bg-red-50{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.bg-red-50\/40{background-color:#fef2f266}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.bg-sky-500{--tw-bg-opacity: 1;background-color:rgb(14 165 233 / var(--tw-bg-opacity, 1))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\/10{background-color:#ffffff1a}.bg-white\/5{background-color:#ffffff0d}.bg-white\/95{background-color:#fffffff2}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.bg-gradient-to-r{background-image:linear-gradient(to right,var(--tw-gradient-stops))}.bg-gradient-to-t{background-image:linear-gradient(to top,var(--tw-gradient-stops))}.from-black\/70{--tw-gradient-from: rgb(0 0 0 / .7) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-black\/85{--tw-gradient-from: rgb(0 0 0 / .85) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-neutral-700{--tw-gradient-from: #404040 var(--tw-gradient-from-position);--tw-gradient-to: rgb(64 64 64 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-neutral-950{--tw-gradient-from: #0a0a0a var(--tw-gradient-from-position);--tw-gradient-to: rgb(10 10 10 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-transparent{--tw-gradient-from: transparent var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.via-black\/10{--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(0 0 0 / .1) var(--tw-gradient-via-position), var(--tw-gradient-to)}.via-black\/20{--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(0 0 0 / .2) var(--tw-gradient-via-position), var(--tw-gradient-to)}.via-neutral-950\/80{--tw-gradient-to: rgb(10 10 10 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(10 10 10 / .8) var(--tw-gradient-via-position), var(--tw-gradient-to)}.via-white\/40{--tw-gradient-to: rgb(255 255 255 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), rgb(255 255 255 / .4) var(--tw-gradient-via-position), var(--tw-gradient-to)}.to-black\/40{--tw-gradient-to: rgb(0 0 0 / .4) var(--tw-gradient-to-position)}.to-neutral-900{--tw-gradient-to: #171717 var(--tw-gradient-to-position)}.to-neutral-950\/40{--tw-gradient-to: rgb(10 10 10 / .4) var(--tw-gradient-to-position)}.to-transparent{--tw-gradient-to: transparent var(--tw-gradient-to-position)}.object-contain{-o-object-fit:contain;object-fit:contain}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0\.5{padding:.125rem}.p-1{padding:.25rem}.p-1\.5{padding:.375rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.p-8{padding:2rem}.p-\[22px\]{padding:22px}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.px-\[22px\]{padding-left:22px;padding-right:22px}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-16{padding-top:4rem;padding-bottom:4rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-20{padding-top:5rem;padding-bottom:5rem}.py-24{padding-top:6rem;padding-bottom:6rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-3\.5{padding-top:.875rem;padding-bottom:.875rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-8{padding-top:2rem;padding-bottom:2rem}.py-\[22px\]{padding-top:22px;padding-bottom:22px}.py-\[26px\]{padding-top:26px;padding-bottom:26px}.pb-10{padding-bottom:2.5rem}.pb-12{padding-bottom:3rem}.pb-24{padding-bottom:6rem}.pb-3{padding-bottom:.75rem}.pb-4{padding-bottom:1rem}.pb-5{padding-bottom:1.25rem}.pb-6{padding-bottom:1.5rem}.pl-5{padding-left:1.25rem}.pl-6{padding-left:1.5rem}.pl-\[42px\]{padding-left:42px}.pr-4{padding-right:1rem}.pr-8{padding-right:2rem}.pt-0\.5{padding-top:.125rem}.pt-1{padding-top:.25rem}.pt-10{padding-top:2.5rem}.pt-12{padding-top:3rem}.pt-3{padding-top:.75rem}.pt-3\.5{padding-top:.875rem}.pt-4{padding-top:1rem}.pt-5{padding-top:1.25rem}.pt-6{padding-top:1.5rem}.pt-8{padding-top:2rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.font-sans{font-family:var(--site-font, ui-sans-serif, system-ui, sans-serif)}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-\[10px\]{font-size:10px}.text-\[11px\]{font-size:11px}.text-\[13px\]{font-size:13px}.text-\[15px\]{font-size:15px}.text-\[17px\]{font-size:17px}.text-\[34px\]{font-size:34px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-extrabold{font-weight:800}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.normal-case{text-transform:none}.italic{font-style:italic}.leading-\[1\.08\]{line-height:1.08}.leading-\[1\.4\]{line-height:1.4}.leading-\[1\.55\]{line-height:1.55}.leading-none{line-height:1}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.tracking-\[0\.2em\]{letter-spacing:.2em}.tracking-\[2px\]{letter-spacing:2px}.tracking-\[3px\]{letter-spacing:3px}.tracking-\[4px\]{letter-spacing:4px}.tracking-\[6px\]{letter-spacing:6px}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.tracking-wider{letter-spacing:.05em}.tracking-widest{letter-spacing:.1em}.text-amber-400{--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.text-amber-600{--tw-text-opacity: 1;color:rgb(217 119 6 / var(--tw-text-opacity, 1))}.text-amber-700{--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity, 1))}.text-amber-800{--tw-text-opacity: 1;color:rgb(146 64 14 / var(--tw-text-opacity, 1))}.text-amber-900{--tw-text-opacity: 1;color:rgb(120 53 15 / var(--tw-text-opacity, 1))}.text-brand-300{--tw-text-opacity: 1;color:rgb(182 227 130 / var(--tw-text-opacity, 1))}.text-brand-400{--tw-text-opacity: 1;color:rgb(146 212 68 / var(--tw-text-opacity, 1))}.text-brand-500{--tw-text-opacity: 1;color:rgb(107 166 38 / var(--tw-text-opacity, 1))}.text-brand-500\/10{color:#6ba6261a}.text-brand-600{--tw-text-opacity: 1;color:rgb(88 137 31 / var(--tw-text-opacity, 1))}.text-brand-700{--tw-text-opacity: 1;color:rgb(72 112 26 / var(--tw-text-opacity, 1))}.text-brand-800{--tw-text-opacity: 1;color:rgb(59 91 21 / var(--tw-text-opacity, 1))}.text-green-600{--tw-text-opacity: 1;color:rgb(22 163 74 / var(--tw-text-opacity, 1))}.text-green-700{--tw-text-opacity: 1;color:rgb(21 128 61 / var(--tw-text-opacity, 1))}.text-green-800{--tw-text-opacity: 1;color:rgb(22 101 52 / var(--tw-text-opacity, 1))}.text-neutral-200{--tw-text-opacity: 1;color:rgb(229 229 229 / var(--tw-text-opacity, 1))}.text-neutral-300{--tw-text-opacity: 1;color:rgb(212 212 212 / var(--tw-text-opacity, 1))}.text-neutral-400{--tw-text-opacity: 1;color:rgb(163 163 163 / var(--tw-text-opacity, 1))}.text-neutral-500{--tw-text-opacity: 1;color:rgb(115 115 115 / var(--tw-text-opacity, 1))}.text-neutral-600{--tw-text-opacity: 1;color:rgb(82 82 82 / var(--tw-text-opacity, 1))}.text-neutral-700{--tw-text-opacity: 1;color:rgb(64 64 64 / var(--tw-text-opacity, 1))}.text-neutral-800{--tw-text-opacity: 1;color:rgb(38 38 38 / var(--tw-text-opacity, 1))}.text-neutral-900{--tw-text-opacity: 1;color:rgb(23 23 23 / var(--tw-text-opacity, 1))}.text-neutral-950{--tw-text-opacity: 1;color:rgb(10 10 10 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.text-red-700{--tw-text-opacity: 1;color:rgb(185 28 28 / var(--tw-text-opacity, 1))}.text-red-800{--tw-text-opacity: 1;color:rgb(153 27 27 / var(--tw-text-opacity, 1))}.text-slate-900{--tw-text-opacity: 1;color:rgb(15 23 42 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-white\/70{color:#ffffffb3}.text-white\/80{color:#fffc}.underline{text-decoration-line:underline}.line-through{text-decoration-line:line-through}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\[0_-8px_24px_rgba\(0\,0\,0\,0\.08\)\]{--tw-shadow: 0 -8px 24px rgba(0,0,0,.08);--tw-shadow-colored: 0 -8px 24px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\[0_0_10px_rgba\(107\,166\,38\,0\.7\)\]{--tw-shadow: 0 0 10px rgba(107,166,38,.7);--tw-shadow-colored: 0 0 10px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-brand-500\/30{--tw-shadow-color: rgb(107 166 38 / .3);--tw-shadow: var(--tw-shadow-colored)}.shadow-neutral-900\/20{--tw-shadow-color: rgb(23 23 23 / .2);--tw-shadow: var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-4{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-brand-400{--tw-ring-opacity: 1;--tw-ring-color: rgb(146 212 68 / var(--tw-ring-opacity, 1))}.ring-brand-500{--tw-ring-opacity: 1;--tw-ring-color: rgb(107 166 38 / var(--tw-ring-opacity, 1))}.ring-brand-500\/30{--tw-ring-color: rgb(107 166 38 / .3)}.ring-brand-500\/40{--tw-ring-color: rgb(107 166 38 / .4)}.ring-neutral-600{--tw-ring-opacity: 1;--tw-ring-color: rgb(82 82 82 / var(--tw-ring-opacity, 1))}.ring-white{--tw-ring-opacity: 1;--tw-ring-color: rgb(255 255 255 / var(--tw-ring-opacity, 1))}.ring-white\/50{--tw-ring-color: rgb(255 255 255 / .5)}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.grayscale{--tw-grayscale: grayscale(100%);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur{--tw-backdrop-blur: blur(8px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-xl{--tw-backdrop-blur: blur(24px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\[filter\,box-shadow\]{transition-property:filter,box-shadow;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\[width\]{transition-property:width;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-shadow{transition-property:box-shadow;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}.duration-500{transition-duration:.5s}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.will-change-transform{will-change:transform}.\[scrollbar-width\:none\]{scrollbar-width:none}html{scroll-behavior:smooth}.marquee-viewport{-webkit-mask-image:linear-gradient(to right,transparent,black 6%,black 94%,transparent);mask-image:linear-gradient(to right,transparent,black 6%,black 94%,transparent)}.page-texture{background-color:#f6f5f0;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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.13 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");background-size:180px 180px}.dark .page-texture{background-color:#0a0b07;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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.14 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")}.kf-page{--kf-pagebg: linear-gradient(120deg, #eef0ea 0%, #f6f8f3 45%, #fbfcf9 100%);--kf-card: #ffffff;--kf-cardbrd: #e4e8dc;--kf-text: #23271d;--kf-text2: #2a2e24;--kf-muted: #6c7360;--kf-label: #5f6650;--kf-field: #fafcf6;--kf-fieldbrd: #dde2d3;--kf-fieldicon: #a7ad9d;--kf-accent: #a4d417;--kf-accent2: #4f7a00;--kf-accentsoft: #f2f8df;--kf-pill: #ffffff;--kf-pillbrd: #dfe4d6;--kf-shadow: 0 24px 60px rgba(60, 70, 40, .08);--kf-shadow2: 0 16px 40px rgba(60, 70, 40, .06);--kf-divider: #e8ecdf;--kf-topo: #d7dccd;--kf-pkgbg: #f4fbe4;--kf-pkgbrd: #cfe89a;--kf-btntext: #1f2417;--kf-scrim: linear-gradient(90deg, rgba(244, 246, 241, .35) 0%, rgba(244, 246, 241, .55) 55%, rgba(246, 248, 243, 1) 100%)}.dark .kf-page{--kf-pagebg: linear-gradient(120deg, #181b0f 0%, #111409 45%, #0a0c06 100%);--kf-card: #14170e;--kf-cardbrd: rgba(168, 225, 12, .16);--kf-text: #f3f6ea;--kf-text2: #e8ece0;--kf-muted: #9aa38c;--kf-label: #8f987f;--kf-field: rgba(0, 0, 0, .35);--kf-fieldbrd: #2c3323;--kf-fieldicon: #5f6852;--kf-accent: #a8e10c;--kf-accent2: #b6e619;--kf-accentsoft: rgba(168, 225, 12, .1);--kf-pill: #14170e;--kf-pillbrd: rgba(168, 225, 12, .28);--kf-shadow: 0 24px 60px rgba(0, 0, 0, .55);--kf-shadow2: 0 16px 40px rgba(0, 0, 0, .45);--kf-divider: rgba(168, 225, 12, .15);--kf-pkgbg: rgba(168, 225, 12, .08);--kf-pkgbrd: rgba(168, 225, 12, .4);--kf-btntext: #0f1208}.kontakt-sektion{background-image:url(/assets/bg-light-CBAG2tPV.webp);background-size:cover;background-position:center}.dark .kontakt-sektion{background-image:url(/assets/bg-dark-B4R1klEI.webp)}.kf-page input::-moz-placeholder,.kf-page textarea::-moz-placeholder{color:var(--kf-fieldicon)}.kf-page input::placeholder,.kf-page textarea::placeholder{color:var(--kf-fieldicon)}.kf-page input:focus,.kf-page textarea:focus{border-color:var(--kf-accent)!important;box-shadow:0 0 0 3px #a4d41733}.grain-band{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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.13 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");background-size:180px 180px}.dark .grain-band{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.7' numOctaves='3' stitchTiles='stitch' result='noise'/%3E%3CfeColorMatrix in='noise' type='matrix' values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.14 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E")}html.hifi-cursor-on,html.hifi-cursor-on *{cursor:none!important}html.hifi-cursor-on :is(input,textarea,[contenteditable=true]){cursor:auto!important}.hifi-cursor{position:fixed;top:0;right:0;bottom:0;left:0;pointer-events:none;z-index:99999;opacity:1;transition:opacity .2s ease}.hifi-cursor[data-hidden=true]{opacity:0}.hifi-cursor__core{position:fixed;top:0;left:0;width:10px;height:10px;margin:-5px 0 0 -5px;border-radius:9999px;background:#7fd44a;box-shadow:0 0 0 1.5px #ffffffe6,0 0 10px #7fd44abf;transition:width .18s ease,height .18s ease,margin .18s ease,background-color .18s ease,opacity .15s ease}.hifi-cursor__orbit{position:fixed;top:0;left:0;opacity:0;transition:opacity .18s ease}.hifi-cursor__ring{position:absolute;width:38px;height:15px;margin:-7.5px 0 0 -19px;border:1px solid rgba(139,234,60,.85);border-radius:50%;transform:rotate(-24deg) scale(.6);transition:transform .22s ease}.hifi-cursor__sat{position:absolute;width:5px;height:5px;margin:-2.5px 0 0 -2.5px;border-radius:9999px;background:#eaffdb;box-shadow:0 0 6px #8bea3ce6}.hifi-cursor[data-state=hover] .hifi-cursor__orbit{opacity:1}.hifi-cursor[data-state=hover] .hifi-cursor__core{width:16px;height:16px;margin:-8px 0 0 -8px;background:#8bea3c;box-shadow:0 0 0 1.5px #fffffff2,0 0 12px #8bea3cd9}.hifi-cursor[data-state=hover] .hifi-cursor__ring{transform:rotate(-24deg) scale(1.45)}.hifi-cursor[data-state=text] .hifi-cursor__core,.hifi-cursor[data-state=text] .hifi-cursor__orbit{opacity:0}.hifi-cursor[data-down=true] .hifi-cursor__core{width:20px;height:20px;margin:-10px 0 0 -10px}.hifi-cursor__pulse{position:fixed;top:0;left:0;width:12px;height:12px;margin:-6px 0 0 -6px;border-radius:9999px;border:1.5px solid rgba(139,234,60,.9);opacity:0}.hifi-cursor__pulse.is-live{animation:hifi-cursor-pulse .45s ease-out forwards}@keyframes hifi-cursor-pulse{0%{opacity:.9;transform:scale(1)}to{opacity:0;transform:scale(3.2)}}.rte-content ul{list-style:disc;padding-left:1.5rem}.rte-content ol{list-style:decimal;padding-left:1.5rem}.rte-content a{color:#3b82f6;text-decoration:underline}.rte-content p{margin:.25rem 0}.rte-content h2{font-size:1.125rem;font-weight:700;margin:.75rem 0 .25rem}.rte-content code{font-family:ui-monospace,monospace;background:#7d7d7d26;border-radius:.25rem;padding:.1rem .3rem;font-size:.85em}.legal-content h2{margin:2rem 0 .5rem;font-weight:600;color:#171717}.dark .legal-content h2{color:#fff}.legal-content h2:first-child{margin-top:0}.legal-content p{margin:.5rem 0}.legal-content ul{list-style:disc;padding-left:1.25rem;margin:.5rem 0}.legal-content li{margin:.25rem 0}.legal-content a{color:#6ba626;text-decoration:underline}.legal-content code{font-family:ui-monospace,monospace;background:#7d7d7d26;border-radius:.25rem;padding:.1rem .3rem;font-size:.85em}.file\:mr-3::file-selector-button{margin-right:.75rem}.file\:rounded-md::file-selector-button{border-radius:.375rem}.file\:border-0::file-selector-button{border-width:0px}.file\:bg-brand-500::file-selector-button{--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.file\:px-3::file-selector-button{padding-left:.75rem;padding-right:.75rem}.file\:py-2::file-selector-button{padding-top:.5rem;padding-bottom:.5rem}.file\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\:font-semibold::file-selector-button{font-weight:600}.file\:text-white::file-selector-button{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.last\:border-b-0:last-child{border-bottom-width:0px}.hover\:-translate-y-0\.5:hover{--tw-translate-y: -.125rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:scale-105:hover{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:border-\[var\(--kf-accent\)\]:hover{border-color:var(--kf-accent)}.hover\:border-brand-500:hover{--tw-border-opacity: 1;border-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.hover\:border-neutral-400:hover{--tw-border-opacity: 1;border-color:rgb(163 163 163 / var(--tw-border-opacity, 1))}.hover\:bg-\[var\(--kf-accentsoft\)\]:hover{background-color:var(--kf-accentsoft)}.hover\:bg-amber-100:hover{--tw-bg-opacity: 1;background-color:rgb(254 243 199 / var(--tw-bg-opacity, 1))}.hover\:bg-brand-400:hover{--tw-bg-opacity: 1;background-color:rgb(146 212 68 / var(--tw-bg-opacity, 1))}.hover\:bg-brand-50:hover{--tw-bg-opacity: 1;background-color:rgb(245 251 238 / var(--tw-bg-opacity, 1))}.hover\:bg-brand-600:hover{--tw-bg-opacity: 1;background-color:rgb(88 137 31 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-100:hover{--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 229 229 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-50:hover{--tw-bg-opacity: 1;background-color:rgb(250 250 250 / var(--tw-bg-opacity, 1))}.hover\:bg-neutral-800:hover{--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.hover\:bg-red-50:hover{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.hover\:bg-red-700:hover{--tw-bg-opacity: 1;background-color:rgb(185 28 28 / var(--tw-bg-opacity, 1))}.hover\:bg-white\/10:hover{background-color:#ffffff1a}.hover\:bg-white\/15:hover{background-color:#ffffff26}.hover\:bg-white\/20:hover{background-color:#fff3}.hover\:text-brand-500:hover{--tw-text-opacity: 1;color:rgb(107 166 38 / var(--tw-text-opacity, 1))}.hover\:text-brand-600:hover{--tw-text-opacity: 1;color:rgb(88 137 31 / var(--tw-text-opacity, 1))}.hover\:text-neutral-600:hover{--tw-text-opacity: 1;color:rgb(82 82 82 / var(--tw-text-opacity, 1))}.hover\:text-neutral-700:hover{--tw-text-opacity: 1;color:rgb(64 64 64 / var(--tw-text-opacity, 1))}.hover\:text-red-600:hover{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.hover\:text-white:hover{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:opacity-80:hover{opacity:.8}.hover\:shadow-lg:hover{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.hover\:shadow-md:hover{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.hover\:brightness-110:hover{--tw-brightness: brightness(1.1);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.hover\:grayscale-0:hover{--tw-grayscale: grayscale(0);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.hover\:file\:bg-brand-600::file-selector-button:hover{--tw-bg-opacity: 1;background-color:rgb(88 137 31 / var(--tw-bg-opacity, 1))}.focus\:border-brand-500:focus{--tw-border-opacity: 1;border-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-brand-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(107 166 38 / var(--tw-ring-opacity, 1))}.active\:cursor-grabbing:active{cursor:grabbing}.disabled\:opacity-40:disabled{opacity:.4}.disabled\:opacity-50:disabled{opacity:.5}.disabled\:opacity-60:disabled{opacity:.6}.group:hover .group-hover\:scale-105{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:from-black\/95{--tw-gradient-from: rgb(0 0 0 / .95) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.peer:checked~.peer-checked\:translate-x-5{--tw-translate-x: 1.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.peer:checked~.peer-checked\:bg-brand-500{--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.peer:disabled~.peer-disabled\:opacity-60{opacity:.6}.dark\:block:is(.dark *){display:block}.dark\:hidden:is(.dark *){display:none}.dark\:divide-neutral-800:is(.dark *)>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(38 38 38 / var(--tw-divide-opacity, 1))}.dark\:border-amber-700:is(.dark *){--tw-border-opacity: 1;border-color:rgb(180 83 9 / var(--tw-border-opacity, 1))}.dark\:border-amber-900:is(.dark *){--tw-border-opacity: 1;border-color:rgb(120 53 15 / var(--tw-border-opacity, 1))}.dark\:border-green-900:is(.dark *){--tw-border-opacity: 1;border-color:rgb(20 83 45 / var(--tw-border-opacity, 1))}.dark\:border-neutral-700:is(.dark *){--tw-border-opacity: 1;border-color:rgb(64 64 64 / var(--tw-border-opacity, 1))}.dark\:border-neutral-800:is(.dark *){--tw-border-opacity: 1;border-color:rgb(38 38 38 / var(--tw-border-opacity, 1))}.dark\:border-red-900:is(.dark *){--tw-border-opacity: 1;border-color:rgb(127 29 29 / var(--tw-border-opacity, 1))}.dark\:border-t-brand-500:is(.dark *){--tw-border-opacity: 1;border-top-color:rgb(107 166 38 / var(--tw-border-opacity, 1))}.dark\:bg-amber-900\/20:is(.dark *){background-color:#78350f33}.dark\:bg-amber-900\/30:is(.dark *){background-color:#78350f4d}.dark\:bg-amber-900\/40:is(.dark *){background-color:#78350f66}.dark\:bg-amber-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(69 26 3 / var(--tw-bg-opacity, 1))}.dark\:bg-amber-950\/40:is(.dark *){background-color:#451a0366}.dark\:bg-brand-500:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(107 166 38 / var(--tw-bg-opacity, 1))}.dark\:bg-brand-900\/20:is(.dark *){background-color:#304b1133}.dark\:bg-brand-900\/40:is(.dark *){background-color:#304b1166}.dark\:bg-green-900\/20:is(.dark *){background-color:#14532d33}.dark\:bg-green-900\/40:is(.dark *){background-color:#14532d66}.dark\:bg-green-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(5 46 22 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-100:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-600:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(82 82 82 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-700:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(64 64 64 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-800:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-800\/50:is(.dark *){background-color:#26262680}.dark\:bg-neutral-900:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(23 23 23 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-900\/40:is(.dark *){background-color:#17171766}.dark\:bg-neutral-900\/95:is(.dark *){background-color:#171717f2}.dark\:bg-neutral-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(10 10 10 / var(--tw-bg-opacity, 1))}.dark\:bg-neutral-950\/95:is(.dark *){background-color:#0a0a0af2}.dark\:bg-red-900\/10:is(.dark *){background-color:#7f1d1d1a}.dark\:bg-red-900\/20:is(.dark *){background-color:#7f1d1d33}.dark\:bg-red-900\/40:is(.dark *){background-color:#7f1d1d66}.dark\:bg-red-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(69 10 10 / var(--tw-bg-opacity, 1))}.dark\:bg-slate-950:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(2 6 23 / var(--tw-bg-opacity, 1))}.dark\:bg-white\/10:is(.dark *){background-color:#ffffff1a}.dark\:text-amber-200:is(.dark *){--tw-text-opacity: 1;color:rgb(253 230 138 / var(--tw-text-opacity, 1))}.dark\:text-amber-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 211 77 / var(--tw-text-opacity, 1))}.dark\:text-amber-400:is(.dark *){--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.dark\:text-brand-200:is(.dark *){--tw-text-opacity: 1;color:rgb(211 238 180 / var(--tw-text-opacity, 1))}.dark\:text-brand-300:is(.dark *){--tw-text-opacity: 1;color:rgb(182 227 130 / var(--tw-text-opacity, 1))}.dark\:text-brand-400:is(.dark *){--tw-text-opacity: 1;color:rgb(146 212 68 / var(--tw-text-opacity, 1))}.dark\:text-brand-400\/10:is(.dark *){color:#92d4441a}.dark\:text-green-200:is(.dark *){--tw-text-opacity: 1;color:rgb(187 247 208 / var(--tw-text-opacity, 1))}.dark\:text-green-300:is(.dark *){--tw-text-opacity: 1;color:rgb(134 239 172 / var(--tw-text-opacity, 1))}.dark\:text-green-400:is(.dark *){--tw-text-opacity: 1;color:rgb(74 222 128 / var(--tw-text-opacity, 1))}.dark\:text-neutral-100:is(.dark *){--tw-text-opacity: 1;color:rgb(245 245 245 / var(--tw-text-opacity, 1))}.dark\:text-neutral-200:is(.dark *){--tw-text-opacity: 1;color:rgb(229 229 229 / var(--tw-text-opacity, 1))}.dark\:text-neutral-300:is(.dark *){--tw-text-opacity: 1;color:rgb(212 212 212 / var(--tw-text-opacity, 1))}.dark\:text-neutral-400:is(.dark *){--tw-text-opacity: 1;color:rgb(163 163 163 / var(--tw-text-opacity, 1))}.dark\:text-neutral-500:is(.dark *){--tw-text-opacity: 1;color:rgb(115 115 115 / var(--tw-text-opacity, 1))}.dark\:text-neutral-600:is(.dark *){--tw-text-opacity: 1;color:rgb(82 82 82 / var(--tw-text-opacity, 1))}.dark\:text-neutral-900:is(.dark *){--tw-text-opacity: 1;color:rgb(23 23 23 / var(--tw-text-opacity, 1))}.dark\:text-red-200:is(.dark *){--tw-text-opacity: 1;color:rgb(254 202 202 / var(--tw-text-opacity, 1))}.dark\:text-red-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 165 165 / var(--tw-text-opacity, 1))}.dark\:text-red-400:is(.dark *){--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.dark\:text-slate-100:is(.dark *){--tw-text-opacity: 1;color:rgb(241 245 249 / var(--tw-text-opacity, 1))}.dark\:text-white:is(.dark *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.dark\:shadow-black\/40:is(.dark *){--tw-shadow-color: rgb(0 0 0 / .4);--tw-shadow: var(--tw-shadow-colored)}.dark\:ring-neutral-900:is(.dark *){--tw-ring-opacity: 1;--tw-ring-color: rgb(23 23 23 / var(--tw-ring-opacity, 1))}.dark\:hover\:border-neutral-600:hover:is(.dark *){--tw-border-opacity: 1;border-color:rgb(82 82 82 / var(--tw-border-opacity, 1))}.dark\:hover\:bg-brand-900\/20:hover:is(.dark *){background-color:#304b1133}.dark\:hover\:bg-neutral-700:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(64 64 64 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-neutral-800:hover:is(.dark *){--tw-bg-opacity: 1;background-color:rgb(38 38 38 / var(--tw-bg-opacity, 1))}.dark\:hover\:bg-neutral-800\/40:hover:is(.dark *){background-color:#26262666}.dark\:hover\:bg-neutral-800\/50:hover:is(.dark *){background-color:#26262680}.dark\:hover\:bg-red-900\/20:hover:is(.dark *){background-color:#7f1d1d33}.dark\:hover\:bg-red-900\/30:hover:is(.dark *){background-color:#7f1d1d4d}.dark\:hover\:text-brand-400:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(146 212 68 / var(--tw-text-opacity, 1))}.dark\:hover\:text-neutral-200:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(229 229 229 / var(--tw-text-opacity, 1))}.dark\:hover\:text-neutral-300:hover:is(.dark *){--tw-text-opacity: 1;color:rgb(212 212 212 / var(--tw-text-opacity, 1))}@media (min-width: 640px){.sm\:left-4{left:1rem}.sm\:left-8{left:2rem}.sm\:right-4{right:1rem}.sm\:top-\[65px\]{top:65px}.sm\:col-span-2{grid-column:span 2 / span 2}.sm\:-mx-6{margin-left:-1.5rem;margin-right:-1.5rem}.sm\:-mt-\[97px\]{margin-top:-97px}.sm\:block{display:block}.sm\:inline{display:inline}.sm\:hidden{display:none}.sm\:h-16{height:4rem}.sm\:h-20{height:5rem}.sm\:h-96{height:24rem}.sm\:min-h-\[85vh\]{min-height:85vh}.sm\:w-64{width:16rem}.sm\:w-72{width:18rem}.sm\:w-auto{width:auto}.sm\:flex-none{flex:none}.sm\:shrink-0{flex-shrink:0}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.sm\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.sm\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.sm\:grid-cols-8{grid-template-columns:repeat(8,minmax(0,1fr))}.sm\:grid-cols-\[10rem_1fr\]{grid-template-columns:10rem 1fr}.sm\:grid-cols-\[16rem_1fr\]{grid-template-columns:16rem 1fr}.sm\:grid-cols-\[1fr_120px\]{grid-template-columns:1fr 120px}.sm\:grid-cols-\[1fr_120px_1fr\]{grid-template-columns:1fr 120px 1fr}.sm\:flex-row{flex-direction:row}.sm\:items-start{align-items:flex-start}.sm\:items-center{align-items:center}.sm\:justify-between{justify-content:space-between}.sm\:p-10{padding:2.5rem}.sm\:p-5{padding:1.25rem}.sm\:p-6{padding:1.5rem}.sm\:px-10{padding-left:2.5rem;padding-right:2.5rem}.sm\:px-6{padding-left:1.5rem;padding-right:1.5rem}.sm\:px-8{padding-left:2rem;padding-right:2rem}.sm\:py-14{padding-top:3.5rem;padding-bottom:3.5rem}.sm\:py-\[34px\]{padding-top:34px;padding-bottom:34px}.sm\:pb-14{padding-bottom:3.5rem}.sm\:pl-11{padding-left:2.75rem}.sm\:pl-8{padding-left:2rem}.sm\:pt-1{padding-top:.25rem}.sm\:pt-14{padding-top:3.5rem}.sm\:text-3xl{font-size:1.875rem;line-height:2.25rem}.sm\:text-4xl{font-size:2.25rem;line-height:2.5rem}.sm\:text-5xl{font-size:3rem;line-height:1}.sm\:text-\[46px\]{font-size:46px}.sm\:text-lg{font-size:1.125rem;line-height:1.75rem}.sm\:text-sm{font-size:.875rem;line-height:1.25rem}}@media (min-width: 641px){.min-\[641px\]\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.min-\[641px\]\:border-b-0{border-bottom-width:0px}.min-\[641px\]\:border-r{border-right-width:1px}.min-\[641px\]\:last\:border-r-0:last-child{border-right-width:0px}}@media (min-width: 768px){.md\:order-1{order:1}.md\:order-2{order:2}.md\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.md\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (min-width: 901px){.min-\[901px\]\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (min-width: 981px){.min-\[981px\]\:grid-cols-\[minmax\(0\,1\.35fr\)_minmax\(320px\,1fr\)\]{grid-template-columns:minmax(0,1.35fr) minmax(320px,1fr)}}@media (min-width: 1024px){.lg\:col-span-2{grid-column:span 2 / span 2}.lg\:w-80{width:20rem}.lg\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.lg\:text-\[60px\]{font-size:60px}}.\[\&\:\:-webkit-scrollbar\]\:hidden::-webkit-scrollbar{display:none} diff --git a/hifi/assets/index-Tg8iNBwT.js b/hifi/assets/index-Tg8iNBwT.js deleted file mode 100644 index 5eb2283..0000000 --- a/hifi/assets/index-Tg8iNBwT.js +++ /dev/null @@ -1,268 +0,0 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/iconRegistry-CE8benTi.js","assets/music-DPTNgOWL.js","assets/eye-Bf2CUjOF.js","assets/grip-vertical-By7l82Pv.js","assets/trash-2-CnvKO1vQ.js","assets/DownloadsPage-BIItFx8g.js","assets/downloads-B9pqFegV.js","assets/Dashboard-DNZlgdsq.js","assets/ImageOptimizer-DiBozBGF.js","assets/contactRequests-Qfsfq7Lb.js","assets/Brands-DKoTUwWY.js","assets/ImageUploadField-Ds8_wHup.js","assets/resizeImage-C6PvAwh0.js","assets/TextStyleWidget-By2wExOQ.js","assets/SortableList-DRJ1jYgo.js","assets/sortable.esm-DhUbHeHx.js","assets/Models-D3NVlJTw.js","assets/ViewOnSite-CVVA03Ho.js","assets/GalleryBrands-B2uVgrZq.js","assets/GalleryProjects-D3Z0gSrh.js","assets/GalleryPhotos-_0TxVvt5.js","assets/Packages-CJRPrtXw.js","assets/Services-CAauKrT-.js","assets/Faqs-DN4tIka3.js","assets/Partners-Cm2S6bro.js","assets/Downloads-MkUPdkz-.js","assets/HomeSections-BowTW1QH.js","assets/RichTextEditor-kI3KpNag.js","assets/SaveBar-BdqoV5a_.js","assets/ContactRequests-C9ur1i_c.js","assets/WebsiteSettings-C9ZvZCtS.js","assets/LegalSettings-BKkWnLFq.js","assets/EmailSettings-CnX83jWY.js","assets/DatabaseSettings-Dd8MgFmo.js"])))=>i.map(i=>d[i]); -function Ax(e,t){for(var n=0;nr[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();function Gm(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Km={exports:{}},Ho={},qm={exports:{}},K={};/** - * @license React - * react.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var Zs=Symbol.for("react.element"),Dx=Symbol.for("react.portal"),Rx=Symbol.for("react.fragment"),Ix=Symbol.for("react.strict_mode"),Vx=Symbol.for("react.profiler"),Fx=Symbol.for("react.provider"),Ox=Symbol.for("react.context"),zx=Symbol.for("react.forward_ref"),Bx=Symbol.for("react.suspense"),Hx=Symbol.for("react.memo"),$x=Symbol.for("react.lazy"),_d=Symbol.iterator;function Ux(e){return e===null||typeof e!="object"?null:(e=_d&&e[_d]||e["@@iterator"],typeof e=="function"?e:null)}var Ym={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Xm=Object.assign,Zm={};function zr(e,t,n){this.props=e,this.context=t,this.refs=Zm,this.updater=n||Ym}zr.prototype.isReactComponent={};zr.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};zr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Qm(){}Qm.prototype=zr.prototype;function Wu(e,t,n){this.props=e,this.context=t,this.refs=Zm,this.updater=n||Ym}var Gu=Wu.prototype=new Qm;Gu.constructor=Wu;Xm(Gu,zr.prototype);Gu.isPureReactComponent=!0;var Md=Array.isArray,Jm=Object.prototype.hasOwnProperty,Ku={current:null},ep={key:!0,ref:!0,__self:!0,__source:!0};function tp(e,t,n){var r,s={},i=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(i=""+t.key),t)Jm.call(t,r)&&!ep.hasOwnProperty(r)&&(s[r]=t[r]);var a=arguments.length-2;if(a===1)s.children=n;else if(1>>1,A=N[E];if(0>>1;Es(de,F))ies(re,de)?(N[E]=re,N[ie]=F,E=ie):(N[E]=de,N[z]=F,E=z);else if(ies(re,F))N[E]=re,N[ie]=F,E=ie;else break e}}return L}function s(N,L){var F=N.sortIndex-L.sortIndex;return F!==0?F:N.id-L.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var u=[],c=[],d=1,f=null,h=3,y=!1,x=!1,w=!1,b=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(N){for(var L=n(c);L!==null;){if(L.callback===null)r(c);else if(L.startTime<=N)r(c),L.sortIndex=L.expirationTime,t(u,L);else break;L=n(c)}}function k(N){if(w=!1,v(N),!x)if(n(u)!==null)x=!0,q(S);else{var L=n(c);L!==null&&le(k,L.startTime-N)}}function S(N,L){x=!1,w&&(w=!1,m(j),j=-1),y=!0;var F=h;try{for(v(L),f=n(u);f!==null&&(!(f.expirationTime>L)||N&&!O());){var E=f.callback;if(typeof E=="function"){f.callback=null,h=f.priorityLevel;var A=E(f.expirationTime<=L);L=e.unstable_now(),typeof A=="function"?f.callback=A:f===n(u)&&r(u),v(L)}else r(u);f=n(u)}if(f!==null)var se=!0;else{var z=n(c);z!==null&&le(k,z.startTime-L),se=!1}return se}finally{f=null,h=F,y=!1}}var C=!1,P=null,j=-1,M=5,T=-1;function O(){return!(e.unstable_now()-TN||125E?(N.sortIndex=F,t(c,N),n(u)===null&&N===n(c)&&(w?(m(j),j=-1):w=!0,le(k,F-E))):(N.sortIndex=A,t(u,N),x||y||(x=!0,q(S))),N},e.unstable_shouldYield=O,e.unstable_wrapCallback=function(N){var L=h;return function(){var F=h;h=L;try{return N.apply(this,arguments)}finally{h=F}}}})(ap);op.exports=ap;var nv=op.exports;/** - * @license React - * react-dom.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var rv=p,lt=nv;function _(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),gl=Object.prototype.hasOwnProperty,sv=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Ad={},Dd={};function iv(e){return gl.call(Dd,e)?!0:gl.call(Ad,e)?!1:sv.test(e)?Dd[e]=!0:(Ad[e]=!0,!1)}function ov(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function av(e,t,n,r){if(t===null||typeof t>"u"||ov(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ye(e,t,n,r,s,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var Ve={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ve[e]=new Ye(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ve[t]=new Ye(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ve[e]=new Ye(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ve[e]=new Ye(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ve[e]=new Ye(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ve[e]=new Ye(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ve[e]=new Ye(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ve[e]=new Ye(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ve[e]=new Ye(e,5,!1,e.toLowerCase(),null,!1,!1)});var Yu=/[\-:]([a-z])/g;function Xu(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Yu,Xu);Ve[t]=new Ye(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Yu,Xu);Ve[t]=new Ye(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Yu,Xu);Ve[t]=new Ye(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ve[e]=new Ye(e,1,!1,e.toLowerCase(),null,!1,!1)});Ve.xlinkHref=new Ye("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ve[e]=new Ye(e,1,!1,e.toLowerCase(),null,!0,!0)});function Zu(e,t,n,r){var s=Ve.hasOwnProperty(t)?Ve[t]:null;(s!==null?s.type!==0:r||!(2a||s[o]!==i[a]){var u=` -`+s[o].replace(" at new "," at ");return e.displayName&&u.includes("")&&(u=u.replace("",e.displayName)),u}while(1<=o&&0<=a);break}}}finally{va=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?os(e):""}function lv(e){switch(e.tag){case 5:return os(e.type);case 16:return os("Lazy");case 13:return os("Suspense");case 19:return os("SuspenseList");case 0:case 2:case 15:return e=wa(e.type,!1),e;case 11:return e=wa(e.type.render,!1),e;case 1:return e=wa(e.type,!0),e;default:return""}}function wl(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case lr:return"Fragment";case ar:return"Portal";case yl:return"Profiler";case Qu:return"StrictMode";case xl:return"Suspense";case vl:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case cp:return(e.displayName||"Context")+".Consumer";case up:return(e._context.displayName||"Context")+".Provider";case Ju:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ec:return t=e.displayName||null,t!==null?t:wl(e.type)||"Memo";case on:t=e._payload,e=e._init;try{return wl(e(t))}catch{}}return null}function uv(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return wl(t);case 8:return t===Qu?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Pn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function fp(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function cv(e){var t=fp(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var s=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function di(e){e._valueTracker||(e._valueTracker=cv(e))}function hp(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=fp(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function no(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function kl(e,t){var n=t.checked;return ve({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Id(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Pn(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function mp(e,t){t=t.checked,t!=null&&Zu(e,"checked",t,!1)}function bl(e,t){mp(e,t);var n=Pn(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Sl(e,t.type,n):t.hasOwnProperty("defaultValue")&&Sl(e,t.type,Pn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Vd(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Sl(e,t,n){(t!=="number"||no(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var as=Array.isArray;function Sr(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s"+t.valueOf().toString()+"",t=fi.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Ns(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var hs={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},dv=["Webkit","ms","Moz","O"];Object.keys(hs).forEach(function(e){dv.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),hs[t]=hs[e]})});function xp(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||hs.hasOwnProperty(e)&&hs[e]?(""+t).trim():t+"px"}function vp(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=xp(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var fv=ve({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Cl(e,t){if(t){if(fv[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(_(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(_(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(_(61))}if(t.style!=null&&typeof t.style!="object")throw Error(_(62))}}function Tl(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var El=null;function tc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Nl=null,jr=null,Pr=null;function zd(e){if(e=ei(e)){if(typeof Nl!="function")throw Error(_(280));var t=e.stateNode;t&&(t=Ko(t),Nl(e.stateNode,e.type,t))}}function wp(e){jr?Pr?Pr.push(e):Pr=[e]:jr=e}function kp(){if(jr){var e=jr,t=Pr;if(Pr=jr=null,zd(e),t)for(e=0;e>>=0,e===0?32:31-(Sv(e)/jv|0)|0}var hi=64,mi=4194304;function ls(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function oo(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,i=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~s;a!==0?r=ls(a):(i&=o,i!==0&&(r=ls(i)))}else o=n&~s,o!==0?r=ls(o):i!==0&&(r=ls(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,i=t&-t,s>=i||s===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Qs(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Tt(t),e[t]=n}function Ev(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=ps),Yd=" ",Xd=!1;function Bp(e,t){switch(e){case"keyup":return n1.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Hp(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ur=!1;function s1(e,t){switch(e){case"compositionend":return Hp(t);case"keypress":return t.which!==32?null:(Xd=!0,Yd);case"textInput":return e=t.data,e===Yd&&Xd?null:e;default:return null}}function i1(e,t){if(ur)return e==="compositionend"||!uc&&Bp(e,t)?(e=Op(),Vi=oc=dn=null,ur=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=ef(n)}}function Gp(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Gp(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Kp(){for(var e=window,t=no();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=no(e.document)}return t}function cc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function m1(e){var t=Kp(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Gp(n.ownerDocument.documentElement,n)){if(r!==null&&cc(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var s=n.textContent.length,i=Math.min(r.start,s);r=r.end===void 0?i:Math.min(r.end,s),!e.extend&&i>r&&(s=r,r=i,i=s),s=tf(n,i);var o=tf(n,r);s&&o&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,cr=null,Rl=null,ys=null,Il=!1;function nf(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Il||cr==null||cr!==no(r)||(r=cr,"selectionStart"in r&&cc(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),ys&&Rs(ys,r)||(ys=r,r=uo(Rl,"onSelect"),0hr||(e.current=Hl[hr],Hl[hr]=null,hr--)}function ue(e,t){hr++,Hl[hr]=e.current,e.current=t}var Cn={},$e=Nn(Cn),Qe=Nn(!1),Gn=Cn;function _r(e,t){var n=e.type.contextTypes;if(!n)return Cn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in n)s[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Je(e){return e=e.childContextTypes,e!=null}function fo(){me(Qe),me($e)}function cf(e,t,n){if($e.current!==Cn)throw Error(_(168));ue($e,t),ue(Qe,n)}function ng(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(_(108,uv(e)||"Unknown",s));return ve({},n,r)}function ho(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Cn,Gn=$e.current,ue($e,e),ue(Qe,Qe.current),!0}function df(e,t,n){var r=e.stateNode;if(!r)throw Error(_(169));n?(e=ng(e,t,Gn),r.__reactInternalMemoizedMergedChildContext=e,me(Qe),me($e),ue($e,e)):me(Qe),ue(Qe,n)}var Ut=null,qo=!1,Da=!1;function rg(e){Ut===null?Ut=[e]:Ut.push(e)}function C1(e){qo=!0,rg(e)}function _n(){if(!Da&&Ut!==null){Da=!0;var e=0,t=ne;try{var n=Ut;for(ne=1;e>=o,s-=o,Wt=1<<32-Tt(t)+s|n<j?(M=P,P=null):M=P.sibling;var T=h(m,P,v[j],k);if(T===null){P===null&&(P=M);break}e&&P&&T.alternate===null&&t(m,P),g=i(T,g,j),C===null?S=T:C.sibling=T,C=T,P=M}if(j===v.length)return n(m,P),pe&&Dn(m,j),S;if(P===null){for(;jj?(M=P,P=null):M=P.sibling;var O=h(m,P,T.value,k);if(O===null){P===null&&(P=M);break}e&&P&&O.alternate===null&&t(m,P),g=i(O,g,j),C===null?S=O:C.sibling=O,C=O,P=M}if(T.done)return n(m,P),pe&&Dn(m,j),S;if(P===null){for(;!T.done;j++,T=v.next())T=f(m,T.value,k),T!==null&&(g=i(T,g,j),C===null?S=T:C.sibling=T,C=T);return pe&&Dn(m,j),S}for(P=r(m,P);!T.done;j++,T=v.next())T=y(P,m,j,T.value,k),T!==null&&(e&&T.alternate!==null&&P.delete(T.key===null?j:T.key),g=i(T,g,j),C===null?S=T:C.sibling=T,C=T);return e&&P.forEach(function(G){return t(m,G)}),pe&&Dn(m,j),S}function b(m,g,v,k){if(typeof v=="object"&&v!==null&&v.type===lr&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case ci:e:{for(var S=v.key,C=g;C!==null;){if(C.key===S){if(S=v.type,S===lr){if(C.tag===7){n(m,C.sibling),g=s(C,v.props.children),g.return=m,m=g;break e}}else if(C.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===on&&mf(S)===C.type){n(m,C.sibling),g=s(C,v.props),g.ref=ts(m,C,v),g.return=m,m=g;break e}n(m,C);break}else t(m,C);C=C.sibling}v.type===lr?(g=$n(v.props.children,m.mode,k,v.key),g.return=m,m=g):(k=Wi(v.type,v.key,v.props,null,m.mode,k),k.ref=ts(m,g,v),k.return=m,m=k)}return o(m);case ar:e:{for(C=v.key;g!==null;){if(g.key===C)if(g.tag===4&&g.stateNode.containerInfo===v.containerInfo&&g.stateNode.implementation===v.implementation){n(m,g.sibling),g=s(g,v.children||[]),g.return=m,m=g;break e}else{n(m,g);break}else t(m,g);g=g.sibling}g=Ha(v,m.mode,k),g.return=m,m=g}return o(m);case on:return C=v._init,b(m,g,C(v._payload),k)}if(as(v))return x(m,g,v,k);if(Xr(v))return w(m,g,v,k);ki(m,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,g!==null&&g.tag===6?(n(m,g.sibling),g=s(g,v),g.return=m,m=g):(n(m,g),g=Ba(v,m.mode,k),g.return=m,m=g),o(m)):n(m,g)}return b}var Lr=ag(!0),lg=ag(!1),go=Nn(null),yo=null,gr=null,mc=null;function pc(){mc=gr=yo=null}function gc(e){var t=go.current;me(go),e._currentValue=t}function Wl(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Tr(e,t){yo=e,mc=gr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ze=!0),e.firstContext=null)}function yt(e){var t=e._currentValue;if(mc!==e)if(e={context:e,memoizedValue:t,next:null},gr===null){if(yo===null)throw Error(_(308));gr=e,yo.dependencies={lanes:0,firstContext:e}}else gr=gr.next=e;return t}var Fn=null;function yc(e){Fn===null?Fn=[e]:Fn.push(e)}function ug(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,yc(t)):(n.next=s.next,s.next=n),t.interleaved=n,Qt(e,r)}function Qt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var an=!1;function xc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function cg(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function qt(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function vn(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,J&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Qt(e,n)}return s=r.interleaved,s===null?(t.next=t,yc(r)):(t.next=s.next,s.next=t),r.interleaved=t,Qt(e,n)}function Oi(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rc(e,n)}}function pf(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?s=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?s=i=t:i=i.next=t}else s=i=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function xo(e,t,n,r){var s=e.updateQueue;an=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var u=a,c=u.next;u.next=null,o===null?i=c:o.next=c,o=u;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==o&&(a===null?d.firstBaseUpdate=c:a.next=c,d.lastBaseUpdate=u))}if(i!==null){var f=s.baseState;o=0,d=c=u=null,a=i;do{var h=a.lane,y=a.eventTime;if((r&h)===h){d!==null&&(d=d.next={eventTime:y,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var x=e,w=a;switch(h=t,y=n,w.tag){case 1:if(x=w.payload,typeof x=="function"){f=x.call(y,f,h);break e}f=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=w.payload,h=typeof x=="function"?x.call(y,f,h):x,h==null)break e;f=ve({},f,h);break e;case 2:an=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[a]:h.push(a))}else y={eventTime:y,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(c=d=y,u=f):d=d.next=y,o|=h;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;h=a,a=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(!0);if(d===null&&(u=f),s.baseState=u,s.firstBaseUpdate=c,s.lastBaseUpdate=d,t=s.shared.interleaved,t!==null){s=t;do o|=s.lane,s=s.next;while(s!==t)}else i===null&&(s.shared.lanes=0);Yn|=o,e.lanes=o,e.memoizedState=f}}function gf(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Ia.transition;Ia.transition={};try{e(!1),t()}finally{ne=n,Ia.transition=r}}function Tg(){return xt().memoizedState}function _1(e,t,n){var r=kn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Eg(e))Ng(t,n);else if(n=ug(e,t,n,r),n!==null){var s=Ke();Et(n,e,r,s),_g(n,t,r)}}function M1(e,t,n){var r=kn(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Eg(e))Ng(t,s);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,a=i(o,n);if(s.hasEagerState=!0,s.eagerState=a,_t(a,o)){var u=t.interleaved;u===null?(s.next=s,yc(t)):(s.next=u.next,u.next=s),t.interleaved=s;return}}catch{}finally{}n=ug(e,t,s,r),n!==null&&(s=Ke(),Et(n,e,r,s),_g(n,t,r))}}function Eg(e){var t=e.alternate;return e===ye||t!==null&&t===ye}function Ng(e,t){xs=wo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function _g(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rc(e,n)}}var ko={readContext:yt,useCallback:Fe,useContext:Fe,useEffect:Fe,useImperativeHandle:Fe,useInsertionEffect:Fe,useLayoutEffect:Fe,useMemo:Fe,useReducer:Fe,useRef:Fe,useState:Fe,useDebugValue:Fe,useDeferredValue:Fe,useTransition:Fe,useMutableSource:Fe,useSyncExternalStore:Fe,useId:Fe,unstable_isNewReconciler:!1},L1={readContext:yt,useCallback:function(e,t){return Dt().memoizedState=[e,t===void 0?null:t],e},useContext:yt,useEffect:xf,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Bi(4194308,4,bg.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Bi(4194308,4,e,t)},useInsertionEffect:function(e,t){return Bi(4,2,e,t)},useMemo:function(e,t){var n=Dt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Dt();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=_1.bind(null,ye,e),[r.memoizedState,e]},useRef:function(e){var t=Dt();return e={current:e},t.memoizedState=e},useState:yf,useDebugValue:Cc,useDeferredValue:function(e){return Dt().memoizedState=e},useTransition:function(){var e=yf(!1),t=e[0];return e=N1.bind(null,e[1]),Dt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=ye,s=Dt();if(pe){if(n===void 0)throw Error(_(407));n=n()}else{if(n=t(),Ae===null)throw Error(_(349));qn&30||mg(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,xf(gg.bind(null,r,i,e),[e]),r.flags|=2048,$s(9,pg.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=Dt(),t=Ae.identifierPrefix;if(pe){var n=Gt,r=Wt;n=(r&~(1<<32-Tt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Bs++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Vt]=t,e[Fs]=r,zg(e,t,!1,!1),t.stateNode=e;e:{switch(o=Tl(n,r),n){case"dialog":he("cancel",e),he("close",e),s=r;break;case"iframe":case"object":case"embed":he("load",e),s=r;break;case"video":case"audio":for(s=0;sRr&&(t.flags|=128,r=!0,ns(i,!1),t.lanes=4194304)}else{if(!r)if(e=vo(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ns(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!pe)return Oe(t),null}else 2*je()-i.renderingStartTime>Rr&&n!==1073741824&&(t.flags|=128,r=!0,ns(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(n=i.last,n!==null?n.sibling=o:t.child=o,i.last=o)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=je(),t.sibling=null,n=ge.current,ue(ge,r?n&1|2:n&1),t):(Oe(t),null);case 22:case 23:return Lc(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?st&1073741824&&(Oe(t),t.subtreeFlags&6&&(t.flags|=8192)):Oe(t),null;case 24:return null;case 25:return null}throw Error(_(156,t.tag))}function z1(e,t){switch(fc(t),t.tag){case 1:return Je(t.type)&&fo(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ar(),me(Qe),me($e),kc(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return wc(t),null;case 13:if(me(ge),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(_(340));Mr()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return me(ge),null;case 4:return Ar(),null;case 10:return gc(t.type._context),null;case 22:case 23:return Lc(),null;case 24:return null;default:return null}}var Si=!1,He=!1,B1=typeof WeakSet=="function"?WeakSet:Set,D=null;function yr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){be(e,t,r)}else n.current=null}function eu(e,t,n){try{n()}catch(r){be(e,t,r)}}var Nf=!1;function H1(e,t){if(Vl=ao,e=Kp(),cc(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var s=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,a=-1,u=-1,c=0,d=0,f=e,h=null;t:for(;;){for(var y;f!==n||s!==0&&f.nodeType!==3||(a=o+s),f!==i||r!==0&&f.nodeType!==3||(u=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(y=f.firstChild)!==null;)h=f,f=y;for(;;){if(f===e)break t;if(h===n&&++c===s&&(a=o),h===i&&++d===r&&(u=o),(y=f.nextSibling)!==null)break;f=h,h=f.parentNode}f=y}n=a===-1||u===-1?null:{start:a,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(Fl={focusedElem:e,selectionRange:n},ao=!1,D=t;D!==null;)if(t=D,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,D=e;else for(;D!==null;){t=D;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var w=x.memoizedProps,b=x.memoizedState,m=t.stateNode,g=m.getSnapshotBeforeUpdate(t.elementType===t.type?w:St(t.type,w),b);m.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(_(163))}}catch(k){be(t,t.return,k)}if(e=t.sibling,e!==null){e.return=t.return,D=e;break}D=t.return}return x=Nf,Nf=!1,x}function vs(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var i=s.destroy;s.destroy=void 0,i!==void 0&&eu(t,n,i)}s=s.next}while(s!==r)}}function Zo(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function tu(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function $g(e){var t=e.alternate;t!==null&&(e.alternate=null,$g(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Vt],delete t[Fs],delete t[Bl],delete t[j1],delete t[P1])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Ug(e){return e.tag===5||e.tag===3||e.tag===4}function _f(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Ug(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function nu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=co));else if(r!==4&&(e=e.child,e!==null))for(nu(e,t,n),e=e.sibling;e!==null;)nu(e,t,n),e=e.sibling}function ru(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(ru(e,t,n),e=e.sibling;e!==null;)ru(e,t,n),e=e.sibling}var Re=null,jt=!1;function rn(e,t,n){for(n=n.child;n!==null;)Wg(e,t,n),n=n.sibling}function Wg(e,t,n){if(Ft&&typeof Ft.onCommitFiberUnmount=="function")try{Ft.onCommitFiberUnmount($o,n)}catch{}switch(n.tag){case 5:He||yr(n,t);case 6:var r=Re,s=jt;Re=null,rn(e,t,n),Re=r,jt=s,Re!==null&&(jt?(e=Re,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Re.removeChild(n.stateNode));break;case 18:Re!==null&&(jt?(e=Re,n=n.stateNode,e.nodeType===8?Aa(e.parentNode,n):e.nodeType===1&&Aa(e,n),As(e)):Aa(Re,n.stateNode));break;case 4:r=Re,s=jt,Re=n.stateNode.containerInfo,jt=!0,rn(e,t,n),Re=r,jt=s;break;case 0:case 11:case 14:case 15:if(!He&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&eu(n,t,o),s=s.next}while(s!==r)}rn(e,t,n);break;case 1:if(!He&&(yr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){be(n,t,a)}rn(e,t,n);break;case 21:rn(e,t,n);break;case 22:n.mode&1?(He=(r=He)||n.memoizedState!==null,rn(e,t,n),He=r):rn(e,t,n);break;default:rn(e,t,n)}}function Mf(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new B1),t.forEach(function(r){var s=Z1.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function wt(e,t){var n=t.deletions;if(n!==null)for(var r=0;rs&&(s=o),r&=~i}if(r=s,r=je()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*U1(r/1960))-r,10e?16:e,fn===null)var r=!1;else{if(e=fn,fn=null,jo=0,J&6)throw Error(_(331));var s=J;for(J|=4,D=e.current;D!==null;){var i=D,o=i.child;if(D.flags&16){var a=i.deletions;if(a!==null){for(var u=0;uje()-_c?Hn(e,0):Nc|=n),et(e,t)}function Jg(e,t){t===0&&(e.mode&1?(t=mi,mi<<=1,!(mi&130023424)&&(mi=4194304)):t=1);var n=Ke();e=Qt(e,t),e!==null&&(Qs(e,t,n),et(e,n))}function X1(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Jg(e,n)}function Z1(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(_(314))}r!==null&&r.delete(t),Jg(e,n)}var e0;e0=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Qe.current)Ze=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Ze=!1,F1(e,t,n);Ze=!!(e.flags&131072)}else Ze=!1,pe&&t.flags&1048576&&sg(t,po,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Hi(e,t),e=t.pendingProps;var s=_r(t,$e.current);Tr(t,n),s=Sc(null,t,r,e,s,n);var i=jc();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Je(r)?(i=!0,ho(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,xc(t),s.updater=Xo,t.stateNode=s,s._reactInternals=t,Kl(t,r,e,n),t=Xl(null,t,r,!0,i,n)):(t.tag=0,pe&&i&&dc(t),Ue(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Hi(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=J1(r),e=St(r,e),s){case 0:t=Yl(null,t,r,e,n);break e;case 1:t=Cf(null,t,r,e,n);break e;case 11:t=jf(null,t,r,e,n);break e;case 14:t=Pf(null,t,r,St(r.type,e),n);break e}throw Error(_(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),Yl(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),Cf(e,t,r,s,n);case 3:e:{if(Vg(t),e===null)throw Error(_(387));r=t.pendingProps,i=t.memoizedState,s=i.element,cg(e,t),xo(t,r,null,n);var o=t.memoizedState;if(r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){s=Dr(Error(_(423)),t),t=Tf(e,t,r,n,s);break e}else if(r!==s){s=Dr(Error(_(424)),t),t=Tf(e,t,r,n,s);break e}else for(it=xn(t.stateNode.containerInfo.firstChild),ot=t,pe=!0,Pt=null,n=lg(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Mr(),r===s){t=Jt(e,t,n);break e}Ue(e,t,r,n)}t=t.child}return t;case 5:return dg(t),e===null&&Ul(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,Ol(r,s)?o=null:i!==null&&Ol(r,i)&&(t.flags|=32),Ig(e,t),Ue(e,t,o,n),t.child;case 6:return e===null&&Ul(t),null;case 13:return Fg(e,t,n);case 4:return vc(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Lr(t,null,r,n):Ue(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),jf(e,t,r,s,n);case 7:return Ue(e,t,t.pendingProps,n),t.child;case 8:return Ue(e,t,t.pendingProps.children,n),t.child;case 12:return Ue(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,i=t.memoizedProps,o=s.value,ue(go,r._currentValue),r._currentValue=o,i!==null)if(_t(i.value,o)){if(i.children===s.children&&!Qe.current){t=Jt(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){o=i.child;for(var u=a.firstContext;u!==null;){if(u.context===r){if(i.tag===1){u=qt(-1,n&-n),u.tag=2;var c=i.updateQueue;if(c!==null){c=c.shared;var d=c.pending;d===null?u.next=u:(u.next=d.next,d.next=u),c.pending=u}}i.lanes|=n,u=i.alternate,u!==null&&(u.lanes|=n),Wl(i.return,n,t),a.lanes|=n;break}u=u.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(_(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Wl(o,n,t),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===t){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}Ue(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,Tr(t,n),s=yt(s),r=r(s),t.flags|=1,Ue(e,t,r,n),t.child;case 14:return r=t.type,s=St(r,t.pendingProps),s=St(r.type,s),Pf(e,t,r,s,n);case 15:return Dg(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:St(r,s),Hi(e,t),t.tag=1,Je(r)?(e=!0,ho(t)):e=!1,Tr(t,n),Mg(t,r,s),Kl(t,r,s,n),Xl(null,t,r,!0,e,n);case 19:return Og(e,t,n);case 22:return Rg(e,t,n)}throw Error(_(156,t.tag))};function t0(e,t){return Ep(e,t)}function Q1(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function mt(e,t,n,r){return new Q1(e,t,n,r)}function Dc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function J1(e){if(typeof e=="function")return Dc(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Ju)return 11;if(e===ec)return 14}return 2}function bn(e,t){var n=e.alternate;return n===null?(n=mt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Wi(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")Dc(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case lr:return $n(n.children,s,i,t);case Qu:o=8,s|=8;break;case yl:return e=mt(12,n,t,s|2),e.elementType=yl,e.lanes=i,e;case xl:return e=mt(13,n,t,s),e.elementType=xl,e.lanes=i,e;case vl:return e=mt(19,n,t,s),e.elementType=vl,e.lanes=i,e;case dp:return Jo(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case up:o=10;break e;case cp:o=9;break e;case Ju:o=11;break e;case ec:o=14;break e;case on:o=16,r=null;break e}throw Error(_(130,e==null?e:typeof e,""))}return t=mt(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function $n(e,t,n,r){return e=mt(7,e,r,t),e.lanes=n,e}function Jo(e,t,n,r){return e=mt(22,e,r,t),e.elementType=dp,e.lanes=n,e.stateNode={isHidden:!1},e}function Ba(e,t,n){return e=mt(6,e,null,t),e.lanes=n,e}function Ha(e,t,n){return t=mt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function ew(e,t,n,r,s){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=ba(0),this.expirationTimes=ba(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ba(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Rc(e,t,n,r,s,i,o,a,u){return e=new ew(e,t,n,a,u),t===1?(t=1,i===!0&&(t|=8)):t=0,i=mt(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},xc(i),e}function tw(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(i0)}catch(e){console.error(e)}}i0(),ip.exports=ut;var Oc=ip.exports;const EN=Gm(Oc);var Of=Oc;pl.createRoot=Of.createRoot,pl.hydrateRoot=Of.hydrateRoot;/** - * @remix-run/router v1.23.3 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function Ws(){return Ws=Object.assign?Object.assign.bind():function(e){for(var t=1;t"u")throw new Error(t)}function zc(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function aw(){return Math.random().toString(36).substr(2,8)}function Bf(e,t){return{usr:e.state,key:e.key,idx:t}}function lu(e,t,n,r){return n===void 0&&(n=null),Ws({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?$r(t):t,{state:n,key:t&&t.key||r||aw()})}function To(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function $r(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function lw(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,a=hn.Pop,u=null,c=d();c==null&&(c=0,o.replaceState(Ws({},o.state,{idx:c}),""));function d(){return(o.state||{idx:null}).idx}function f(){a=hn.Pop;let b=d(),m=b==null?null:b-c;c=b,u&&u({action:a,location:w.location,delta:m})}function h(b,m){a=hn.Push;let g=lu(w.location,b,m);c=d()+1;let v=Bf(g,c),k=w.createHref(g);try{o.pushState(v,"",k)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;s.location.assign(k)}i&&u&&u({action:a,location:w.location,delta:1})}function y(b,m){a=hn.Replace;let g=lu(w.location,b,m);c=d();let v=Bf(g,c),k=w.createHref(g);o.replaceState(v,"",k),i&&u&&u({action:a,location:w.location,delta:0})}function x(b){let m=s.location.origin!=="null"?s.location.origin:s.location.href,g=typeof b=="string"?b:To(b);return g=g.replace(/ $/,"%20"),xe(m,"No window.location.(origin|href) available to create URL for href: "+g),new URL(g,m)}let w={get action(){return a},get location(){return e(s,o)},listen(b){if(u)throw new Error("A history only accepts one active listener");return s.addEventListener(zf,f),u=b,()=>{s.removeEventListener(zf,f),u=null}},createHref(b){return t(s,b)},createURL:x,encodeLocation(b){let m=x(b);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:h,replace:y,go(b){return o.go(b)}};return w}var Hf;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Hf||(Hf={}));function uw(e,t,n){return n===void 0&&(n="/"),cw(e,t,n)}function cw(e,t,n,r){let s=typeof t=="string"?$r(t):t,i=Ir(s.pathname||"/",n);if(i==null)return null;let o=o0(e);dw(o);let a=null,u=bw(i);for(let c=0;a==null&&c{let u={relativePath:a===void 0?i.path||"":a,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};u.relativePath.startsWith("/")&&(xe(u.relativePath.startsWith(r),'Absolute route path "'+u.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),u.relativePath=u.relativePath.slice(r.length));let c=Sn([r,u.relativePath]),d=n.concat(u);i.children&&i.children.length>0&&(xe(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),o0(i.children,t,d,c)),!(i.path==null&&!i.index)&&t.push({path:c,score:xw(c,i.index),routesMeta:d})};return e.forEach((i,o)=>{var a;if(i.path===""||!((a=i.path)!=null&&a.includes("?")))s(i,o);else for(let u of a0(i.path))s(i,o,u)}),t}function a0(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return s?[i,""]:[i];let o=a0(r.join("/")),a=[];return a.push(...o.map(u=>u===""?i:[i,u].join("/"))),s&&a.push(...o),a.map(u=>e.startsWith("/")&&u===""?"/":u)}function dw(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:vw(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const fw=/^:[\w-]+$/,hw=3,mw=2,pw=1,gw=10,yw=-2,$f=e=>e==="*";function xw(e,t){let n=e.split("/"),r=n.length;return n.some($f)&&(r+=yw),t&&(r+=mw),n.filter(s=>!$f(s)).reduce((s,i)=>s+(fw.test(i)?hw:i===""?pw:gw),r)}function vw(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function ww(e,t,n){let{routesMeta:r}=e,s={},i="/",o=[];for(let a=0;a{let{paramName:h,isOptional:y}=d;if(h==="*"){let w=a[f]||"";o=i.slice(0,i.length-w.length).replace(/(.)\/+$/,"$1")}const x=a[f];return y&&!x?c[h]=void 0:c[h]=(x||"").replace(/%2F/g,"/"),c},{}),pathname:i,pathnameBase:o,pattern:e}}function kw(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),zc(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,u)=>(r.push({paramName:a,isOptional:u!=null}),u?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function bw(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return zc(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Ir(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}const Sw=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,jw=e=>Sw.test(e);function Pw(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?$r(e):e,i;if(n)if(jw(n))i=n;else{if(n.includes("//")){let o=n;n=l0(n),zc(!1,"Pathnames cannot have embedded double slashes - normalizing "+(o+" -> "+n))}n.startsWith("/")?i=Uf(n.substring(1),"/"):i=Uf(n,t)}else i=t;return{pathname:i,search:Ew(r),hash:Nw(s)}}function Uf(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function $a(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in and the router will parse it for you.'}function Cw(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Bc(e,t){let n=Cw(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Hc(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=$r(e):(s=Ws({},e),xe(!s.pathname||!s.pathname.includes("?"),$a("?","pathname","search",s)),xe(!s.pathname||!s.pathname.includes("#"),$a("#","pathname","hash",s)),xe(!s.search||!s.search.includes("#"),$a("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,a;if(o==null)a=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),f-=1;s.pathname=h.join("/")}a=f>=0?t[f]:"/"}let u=Pw(s,a),c=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!u.pathname.endsWith("/")&&(c||d)&&(u.pathname+="/"),u}const l0=e=>e.replace(/\/\/+/g,"/"),Sn=e=>l0(e.join("/")),Tw=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Ew=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Nw=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function _w(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const u0=["post","put","patch","delete"];new Set(u0);const Mw=["get",...u0];new Set(Mw);/** - * React Router v6.30.4 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function Gs(){return Gs=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0}),p.useCallback(function(c,d){if(d===void 0&&(d={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let f=Hc(c,JSON.parse(o),i,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:Sn([t,f.pathname])),(d.replace?r.replace:r.push)(f,d.state,d)},[t,r,o,i,e])}const Dw=p.createContext(null);function Rw(e){let t=p.useContext(Bt).outlet;return t&&p.createElement(Dw.Provider,{value:e},t)}function $c(){let{matches:e}=p.useContext(Bt),t=e[e.length-1];return t?t.params:{}}function aa(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=p.useContext(nn),{matches:s}=p.useContext(Bt),{pathname:i}=nt(),o=JSON.stringify(Bc(s,r.v7_relativeSplatPath));return p.useMemo(()=>Hc(e,JSON.parse(o),i,n==="path"),[e,o,i,n])}function Iw(e,t){return Vw(e,t)}function Vw(e,t,n,r){Ur()||xe(!1);let{navigator:s}=p.useContext(nn),{matches:i}=p.useContext(Bt),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let u=o?o.pathnameBase:"/";o&&o.route;let c=nt(),d;if(t){var f;let b=typeof t=="string"?$r(t):t;u==="/"||(f=b.pathname)!=null&&f.startsWith(u)||xe(!1),d=b}else d=c;let h=d.pathname||"/",y=h;if(u!=="/"){let b=u.replace(/^\//,"").split("/");y="/"+h.replace(/^\//,"").split("/").slice(b.length).join("/")}let x=uw(e,{pathname:y}),w=Hw(x&&x.map(b=>Object.assign({},b,{params:Object.assign({},a,b.params),pathname:Sn([u,s.encodeLocation?s.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?u:Sn([u,s.encodeLocation?s.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),i,n,r);return t&&w?p.createElement(ia.Provider,{value:{location:Gs({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:hn.Pop}},w):w}function Fw(){let e=Gw(),t=_w(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return p.createElement(p.Fragment,null,p.createElement("h2",null,"Unexpected Application Error!"),p.createElement("h3",{style:{fontStyle:"italic"}},t),n?p.createElement("pre",{style:s},n):null,null)}const Ow=p.createElement(Fw,null);class zw extends p.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?p.createElement(Bt.Provider,{value:this.props.routeContext},p.createElement(d0.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Bw(e){let{routeContext:t,match:n,children:r}=e,s=p.useContext(sa);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),p.createElement(Bt.Provider,{value:t},r)}function Hw(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let d=o.findIndex(f=>f.route.id&&(a==null?void 0:a[f.route.id])!==void 0);d>=0||xe(!1),o=o.slice(0,Math.min(o.length,d+1))}let u=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((d,f,h)=>{let y,x=!1,w=null,b=null;n&&(y=a&&f.route.id?a[f.route.id]:void 0,w=f.route.errorElement||Ow,u&&(c<0&&h===0?(qw("route-fallback"),x=!0,b=null):c===h&&(x=!0,b=f.route.hydrateFallbackElement||null)));let m=t.concat(o.slice(0,h+1)),g=()=>{let v;return y?v=w:x?v=b:f.route.Component?v=p.createElement(f.route.Component,null):f.route.element?v=f.route.element:v=d,p.createElement(Bw,{match:f,routeContext:{outlet:d,matches:m,isDataRoute:n!=null},children:v})};return n&&(f.route.ErrorBoundary||f.route.errorElement||h===0)?p.createElement(zw,{location:n.location,revalidation:n.revalidation,component:w,error:y,children:g(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):g()},null)}var h0=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(h0||{}),m0=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(m0||{});function $w(e){let t=p.useContext(sa);return t||xe(!1),t}function Uw(e){let t=p.useContext(c0);return t||xe(!1),t}function Ww(e){let t=p.useContext(Bt);return t||xe(!1),t}function p0(e){let t=Ww(),n=t.matches[t.matches.length-1];return n.route.id||xe(!1),n.route.id}function Gw(){var e;let t=p.useContext(d0),n=Uw(),r=p0();return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function Kw(){let{router:e}=$w(h0.UseNavigateStable),t=p0(m0.UseNavigateStable),n=p.useRef(!1);return f0(()=>{n.current=!0}),p.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Gs({fromRouteId:t},i)))},[e,t])}const Wf={};function qw(e,t,n){Wf[e]||(Wf[e]=!0)}function Yw(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function Zn(e){let{to:t,replace:n,state:r,relative:s}=e;Ur()||xe(!1);let{future:i,static:o}=p.useContext(nn),{matches:a}=p.useContext(Bt),{pathname:u}=nt(),c=oa(),d=Hc(t,Bc(a,i.v7_relativeSplatPath),u,s==="path"),f=JSON.stringify(d);return p.useEffect(()=>c(JSON.parse(f),{replace:n,state:r,relative:s}),[c,f,s,n,r]),null}function Uc(e){return Rw(e.context)}function B(e){xe(!1)}function Xw(e){let{basename:t="/",children:n=null,location:r,navigationType:s=hn.Pop,navigator:i,static:o=!1,future:a}=e;Ur()&&xe(!1);let u=t.replace(/^\/*/,"/"),c=p.useMemo(()=>({basename:u,navigator:i,static:o,future:Gs({v7_relativeSplatPath:!1},a)}),[u,a,i,o]);typeof r=="string"&&(r=$r(r));let{pathname:d="/",search:f="",hash:h="",state:y=null,key:x="default"}=r,w=p.useMemo(()=>{let b=Ir(d,u);return b==null?null:{location:{pathname:b,search:f,hash:h,state:y,key:x},navigationType:s}},[u,d,f,h,y,x,s]);return w==null?null:p.createElement(nn.Provider,{value:c},p.createElement(ia.Provider,{children:n,value:w}))}function Zw(e){let{children:t,location:n}=e;return Iw(cu(t),n)}new Promise(()=>{});function cu(e,t){t===void 0&&(t=[]);let n=[];return p.Children.forEach(e,(r,s)=>{if(!p.isValidElement(r))return;let i=[...t,s];if(r.type===p.Fragment){n.push.apply(n,cu(r.props.children,i));return}r.type!==B&&xe(!1),!r.props.index||!r.props.children||xe(!1);let o={id:r.props.id||i.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=cu(r.props.children,i)),n.push(o)}),n}/** - * React Router DOM v6.30.4 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function Eo(){return Eo=Object.assign?Object.assign.bind():function(e){for(var t=1;t{let r=e[n];return t.concat(Array.isArray(r)?r.map(s=>[n,s]):[[n,r]])},[]))}function ek(e,t){let n=du(e);return t&&t.forEach((r,s)=>{n.has(s)||t.getAll(s).forEach(i=>{n.append(s,i)})}),n}const tk=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],nk=["aria-current","caseSensitive","className","end","style","to","viewTransition","children"],rk="6";try{window.__reactRouterVersion=rk}catch{}const sk=p.createContext({isTransitioning:!1}),ik="startTransition",Gf=Yx[ik];function ok(e){let{basename:t,children:n,future:r,window:s}=e,i=p.useRef();i.current==null&&(i.current=ow({window:s,v5Compat:!0}));let o=i.current,[a,u]=p.useState({action:o.action,location:o.location}),{v7_startTransition:c}=r||{},d=p.useCallback(f=>{c&&Gf?Gf(()=>u(f)):u(f)},[u,c]);return p.useLayoutEffect(()=>o.listen(d),[o,d]),p.useEffect(()=>Yw(r),[r]),p.createElement(Xw,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}const ak=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",lk=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,U=p.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:i,replace:o,state:a,target:u,to:c,preventScrollReset:d,viewTransition:f}=t,h=g0(t,tk),{basename:y}=p.useContext(nn),x,w=!1;if(typeof c=="string"&&lk.test(c)&&(x=c,ak))try{let v=new URL(window.location.href),k=c.startsWith("//")?new URL(v.protocol+c):new URL(c),S=Ir(k.pathname,y);k.origin===v.origin&&S!=null?c=S+k.search+k.hash:w=!0}catch{}let b=Lw(c,{relative:s}),m=ck(c,{replace:o,state:a,target:u,preventScrollReset:d,relative:s,viewTransition:f});function g(v){r&&r(v),v.defaultPrevented||m(v)}return p.createElement("a",Eo({},h,{href:x||b,onClick:w||i?r:g,ref:n,target:u}))}),cs=p.forwardRef(function(t,n){let{"aria-current":r="page",caseSensitive:s=!1,className:i="",end:o=!1,style:a,to:u,viewTransition:c,children:d}=t,f=g0(t,nk),h=aa(u,{relative:f.relative}),y=nt(),x=p.useContext(c0),{navigator:w,basename:b}=p.useContext(nn),m=x!=null&&fk(h)&&c===!0,g=w.encodeLocation?w.encodeLocation(h).pathname:h.pathname,v=y.pathname,k=x&&x.navigation&&x.navigation.location?x.navigation.location.pathname:null;s||(v=v.toLowerCase(),k=k?k.toLowerCase():null,g=g.toLowerCase()),k&&b&&(k=Ir(k,b)||k);const S=g!=="/"&&g.endsWith("/")?g.length-1:g.length;let C=v===g||!o&&v.startsWith(g)&&v.charAt(S)==="/",P=k!=null&&(k===g||!o&&k.startsWith(g)&&k.charAt(g.length)==="/"),j={isActive:C,isPending:P,isTransitioning:m},M=C?r:void 0,T;typeof i=="function"?T=i(j):T=[i,C?"active":null,P?"pending":null,m?"transitioning":null].filter(Boolean).join(" ");let O=typeof a=="function"?a(j):a;return p.createElement(U,Eo({},f,{"aria-current":M,className:T,ref:n,style:O,to:u,viewTransition:c}),typeof d=="function"?d(j):d)});var fu;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(fu||(fu={}));var Kf;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Kf||(Kf={}));function uk(e){let t=p.useContext(sa);return t||xe(!1),t}function ck(e,t){let{target:n,replace:r,state:s,preventScrollReset:i,relative:o,viewTransition:a}=t===void 0?{}:t,u=oa(),c=nt(),d=aa(e,{relative:o});return p.useCallback(f=>{if(Jw(f,n)){f.preventDefault();let h=r!==void 0?r:To(c)===To(d);u(e,{replace:h,state:s,preventScrollReset:i,relative:o,viewTransition:a})}},[c,u,d,r,s,n,e,i,o,a])}function dk(e){let t=p.useRef(du(e)),n=p.useRef(!1),r=nt(),s=p.useMemo(()=>ek(r.search,n.current?null:t.current),[r.search]),i=oa(),o=p.useCallback((a,u)=>{const c=du(typeof a=="function"?a(s):a);n.current=!0,i("?"+c,u)},[i,s]);return[s,o]}function fk(e,t){t===void 0&&(t={});let n=p.useContext(sk);n==null&&xe(!1);let{basename:r}=uk(fu.useViewTransitionState),s=aa(e,{relative:t.relative});if(!n.isTransitioning)return!1;let i=Ir(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=Ir(n.nextLocation.pathname,r)||n.nextLocation.pathname;return uu(s.pathname,o)!=null||uu(s.pathname,i)!=null}const hk="modulepreload",mk=function(e){return"/"+e},qf={},X=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),a=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));s=Promise.allSettled(n.map(u=>{if(u=mk(u),u in qf)return;qf[u]=!0;const c=u.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${u}"]${d}`))return;const f=document.createElement("link");if(f.rel=c?"stylesheet":hk,c||(f.as="script"),f.crossOrigin="",f.href=u,a&&f.setAttribute("nonce",a),document.head.appendChild(f),c)return new Promise((h,y)=>{f.addEventListener("load",h),f.addEventListener("error",()=>y(new Error(`Unable to preload CSS for ${u}`)))})}))}function i(o){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o}return s.then(o=>{for(const a of o||[])a.status==="rejected"&&i(a.reason);return t().catch(i)})},Wc=p.createContext({});function en(e){const t=p.useRef(null);return t.current===null&&(t.current=e()),t.current}const pk=typeof window<"u",ni=pk?p.useLayoutEffect:p.useEffect,la=p.createContext(null);function Gc(e,t){e.indexOf(t)===-1&&e.push(t)}function No(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Mt=(e,t,n)=>n>t?t:n{};const Tn={},y0=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),x0=e=>typeof e=="object"&&e!==null,v0=e=>/^0[^.\s]+$/u.test(e);function w0(e){let t;return()=>(t===void 0&&(t=e()),t)}const tt=e=>e,ri=(...e)=>e.reduce((t,n)=>r=>n(t(r))),Vr=(e,t,n)=>{const r=t-e;return r?(n-e)/r:1};class qc{constructor(){this.subscriptions=[]}add(t){return Gc(this.subscriptions,t),()=>No(this.subscriptions,t)}notify(t,n,r){const s=this.subscriptions.length;if(s)if(s===1)this.subscriptions[0](t,n,r);else for(let i=0;ie*1e3,pt=e=>e/1e3,Yc=(e,t)=>t?e*(1e3/t):0,k0=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,gk=1e-7,yk=12;function xk(e,t,n,r,s){let i,o,a=0;do o=t+(n-t)/2,i=k0(o,r,s)-e,i>0?n=o:t=o;while(Math.abs(i)>gk&&++axk(i,0,1,e,n);return i=>i===0||i===1?i:k0(s(i),t,r)}const b0=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,S0=e=>t=>1-e(1-t),j0=si(.33,1.53,.69,.99),Xc=S0(j0),P0=b0(Xc),C0=e=>e>=1?1:(e*=2)<1?.5*Xc(e):.5*(2-Math.pow(2,-10*(e-1))),Zc=e=>1-Math.sin(Math.acos(e)),T0=S0(Zc),E0=b0(Zc),vk=si(.42,0,1,1),wk=si(0,0,.58,1),N0=si(.42,0,.58,1),kk=e=>Array.isArray(e)&&typeof e[0]!="number",_0=e=>Array.isArray(e)&&typeof e[0]=="number",bk={linear:tt,easeIn:vk,easeInOut:N0,easeOut:wk,circIn:Zc,circInOut:E0,circOut:T0,backIn:Xc,backInOut:P0,backOut:j0,anticipate:C0},Sk=e=>typeof e=="string",Yf=e=>{if(_0(e)){Kc(e.length===4);const[t,n,r,s]=e;return si(t,n,r,s)}else if(Sk(e))return bk[e];return e},Ci=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function jk(e){let t=new Set,n=new Set,r=!1,s=!1;const i=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function a(c){i.has(c)&&(u.schedule(c),e()),c(o)}const u={schedule:(c,d=!1,f=!1)=>{const y=f&&r?t:n;return d&&i.add(c),y.add(c),c},cancel:c=>{n.delete(c),i.delete(c)},process:c=>{if(o=c,r){s=!0;return}r=!0;const d=t;t=n,n=d,t.forEach(a),t.clear(),r=!1,s&&(s=!1,u.process(c))}};return u}const Pk=40;function M0(e,t){let n=!1,r=!0;const s={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,o=Ci.reduce((v,k)=>(v[k]=jk(i),v),{}),{setup:a,read:u,resolveKeyframes:c,preUpdate:d,update:f,preRender:h,render:y,postRender:x}=o,w=()=>{const v=Tn.useManualTiming,k=v?s.timestamp:performance.now();n=!1,v||(s.delta=r?1e3/60:Math.max(Math.min(k-s.timestamp,Pk),1)),s.timestamp=k,s.isProcessing=!0,a.process(s),u.process(s),c.process(s),d.process(s),f.process(s),h.process(s),y.process(s),x.process(s),s.isProcessing=!1,n&&t&&(r=!1,e(w))},b=()=>{n=!0,r=!0,s.isProcessing||e(w)};return{schedule:Ci.reduce((v,k)=>{const S=o[k];return v[k]=(C,P=!1,j=!1)=>(n||b(),S.schedule(C,P,j)),v},{}),cancel:v=>{for(let k=0;k(Gi===void 0&&We.set(Me.isProcessing||Tn.useManualTiming?Me.timestamp:performance.now()),Gi),set:e=>{Gi=e,queueMicrotask(Ck)}},L0=e=>t=>typeof t=="string"&&t.startsWith(e),A0=L0("--"),Tk=L0("var(--"),Qc=e=>Tk(e)?Ek.test(e.split("/*")[0].trim()):!1,Ek=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Xf(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const Wr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Ks={...Wr,transform:e=>Mt(0,1,e)},Ti={...Wr,default:1},bs=e=>Math.round(e*1e5)/1e5,Jc=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Nk(e){return e==null}const _k=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,ed=(e,t)=>n=>!!(typeof n=="string"&&_k.test(n)&&n.startsWith(e)||t&&!Nk(n)&&Object.prototype.hasOwnProperty.call(n,t)),D0=(e,t,n)=>r=>{if(typeof r!="string")return r;const[s,i,o,a]=r.match(Jc);return{[e]:parseFloat(s),[t]:parseFloat(i),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},Mk=e=>Mt(0,255,e),Wa={...Wr,transform:e=>Math.round(Mk(e))},zn={test:ed("rgb","red"),parse:D0("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Wa.transform(e)+", "+Wa.transform(t)+", "+Wa.transform(n)+", "+bs(Ks.transform(r))+")"};function Lk(e){let t="",n="",r="",s="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),s=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),s=e.substring(4,5),t+=t,n+=n,r+=r,s+=s),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:s?parseInt(s,16)/255:1}}const hu={test:ed("#"),parse:Lk,transform:zn.transform},ii=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Ht=ii("deg"),zt=ii("%"),R=ii("px"),Ak=ii("vh"),Dk=ii("vw"),Zf={...zt,parse:e=>zt.parse(e)/100,transform:e=>zt.transform(e*100)},vr={test:ed("hsl","hue"),parse:D0("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+zt.transform(bs(t))+", "+zt.transform(bs(n))+", "+bs(Ks.transform(r))+")"},Pe={test:e=>zn.test(e)||hu.test(e)||vr.test(e),parse:e=>zn.test(e)?zn.parse(e):vr.test(e)?vr.parse(e):hu.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?zn.transform(e):vr.transform(e),getAnimatableNone:e=>{const t=Pe.parse(e);return t.alpha=0,Pe.transform(t)}},Rk=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Ik(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Jc))==null?void 0:t.length)||0)+(((n=e.match(Rk))==null?void 0:n.length)||0)>0}const R0="number",I0="color",Vk="var",Fk="var(",Qf="${}",Ok=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Fr(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},s=[];let i=0;const a=t.replace(Ok,u=>(Pe.test(u)?(r.color.push(i),s.push(I0),n.push(Pe.parse(u))):u.startsWith(Fk)?(r.var.push(i),s.push(Vk),n.push(u)):(r.number.push(i),s.push(R0),n.push(parseFloat(u))),++i,Qf)).split(Qf);return{values:n,split:a,indexes:r,types:s}}function zk(e){return Fr(e).values}function V0({split:e,types:t}){const n=e.length;return r=>{let s="";for(let i=0;itypeof e=="number"?0:Pe.test(e)?Pe.getAnimatableNone(e):e,$k=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:Hk(e);function Uk(e){const t=Fr(e);return V0(t)(t.values.map((r,s)=>$k(r,t.split[s])))}const Nt={test:Ik,parse:zk,createTransformer:Bk,getAnimatableNone:Uk};function Ga(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Wk({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let s=0,i=0,o=0;if(!t)s=i=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,u=2*n-a;s=Ga(u,a,e+1/3),i=Ga(u,a,e),o=Ga(u,a,e-1/3)}return{red:Math.round(s*255),green:Math.round(i*255),blue:Math.round(o*255),alpha:r}}function _o(e,t){return n=>n>0?t:e}const ae=(e,t,n)=>e+(t-e)*n,Ka=(e,t,n)=>{const r=e*e,s=n*(t*t-r)+r;return s<0?0:Math.sqrt(s)},Gk=[hu,zn,vr],Kk=e=>Gk.find(t=>t.test(e));function Jf(e){const t=Kk(e);if(!t)return!1;let n=t.parse(e);return t===vr&&(n=Wk(n)),n}const eh=(e,t)=>{const n=Jf(e),r=Jf(t);if(!n||!r)return _o(e,t);const s={...n};return i=>(s.red=Ka(n.red,r.red,i),s.green=Ka(n.green,r.green,i),s.blue=Ka(n.blue,r.blue,i),s.alpha=ae(n.alpha,r.alpha,i),zn.transform(s))},mu=new Set(["none","hidden"]);function qk(e,t){return mu.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Yk(e,t){return n=>ae(e,t,n)}function td(e){return typeof e=="number"?Yk:typeof e=="string"?Qc(e)?_o:Pe.test(e)?eh:Qk:Array.isArray(e)?F0:typeof e=="object"?Pe.test(e)?eh:Xk:_o}function F0(e,t){const n=[...e],r=n.length,s=e.map((i,o)=>td(i)(i,t[o]));return i=>{for(let o=0;o{for(const i in r)n[i]=r[i](s);return n}}function Zk(e,t){const n=[],r={color:0,var:0,number:0};for(let s=0;s{const n=Nt.createTransformer(t),r=Fr(e),s=Fr(t);return r.indexes.var.length===s.indexes.var.length&&r.indexes.color.length===s.indexes.color.length&&r.indexes.number.length>=s.indexes.number.length?mu.has(e)&&!s.values.length||mu.has(t)&&!r.values.length?qk(e,t):ri(F0(Zk(r,s),s.values),n):_o(e,t)};function O0(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?ae(e,t,n):td(e)(e,t)}const Jk=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>Z.update(t,n),stop:()=>vt(t),now:()=>Me.isProcessing?Me.timestamp:We.now()}},z0=(e,t,n=10)=>{let r="";const s=Math.max(Math.round(t/n),2);for(let i=0;i=Mo?1/0:t}function eb(e,t=100,n){const r=n({...e,keyframes:[0,t]}),s=Math.min(nd(r),Mo);return{type:"keyframes",ease:i=>r.next(s*i).value/t,duration:pt(s)}}const ke={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function pu(e,t){return e*Math.sqrt(1-t*t)}const tb=12;function nb(e,t,n){let r=n;for(let s=1;s{const d=c*o,f=d*e,h=d-n,y=pu(c,o),x=Math.exp(-f);return qa-h/y*x},i=c=>{const f=c*o*e,h=f*n+n,y=Math.pow(o,2)*Math.pow(c,2)*e,x=Math.exp(-f),w=pu(Math.pow(c,2),o);return(-s(c)+qa>0?-1:1)*((h-y)*x)/w}):(s=c=>{const d=Math.exp(-c*e),f=(c-n)*e+1;return-qa+d*f},i=c=>{const d=Math.exp(-c*e),f=(n-c)*(e*e);return d*f});const a=5/e,u=nb(s,i,a);if(e=at(e),isNaN(u))return{stiffness:ke.stiffness,damping:ke.damping,duration:e};{const c=Math.pow(u,2)*r;return{stiffness:c,damping:o*2*Math.sqrt(r*c),duration:e}}}const sb=["duration","bounce"],ib=["stiffness","damping","mass"];function th(e,t){return t.some(n=>e[n]!==void 0)}function ob(e){let t={velocity:ke.velocity,stiffness:ke.stiffness,damping:ke.damping,mass:ke.mass,isResolvedFromDuration:!1,...e};if(!th(e,ib)&&th(e,sb))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),s=r*r,i=2*Mt(.05,1,1-(e.bounce||0))*Math.sqrt(s);t={...t,mass:ke.mass,stiffness:s,damping:i}}else{const n=rb({...e,velocity:0});t={...t,...n,mass:ke.mass},t.isResolvedFromDuration=!0}return t}function Lo(e=ke.visualDuration,t=ke.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:s}=n;const i=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:u,damping:c,mass:d,duration:f,velocity:h,isResolvedFromDuration:y}=ob({...n,velocity:-pt(n.velocity||0)}),x=h||0,w=c/(2*Math.sqrt(u*d)),b=o-i,m=pt(Math.sqrt(u/d)),g=Math.abs(b)<5;r||(r=g?ke.restSpeed.granular:ke.restSpeed.default),s||(s=g?ke.restDelta.granular:ke.restDelta.default);let v,k,S,C,P,j;if(w<1)S=pu(m,w),C=(x+w*m*b)/S,v=T=>{const O=Math.exp(-w*m*T);return o-O*(C*Math.sin(S*T)+b*Math.cos(S*T))},P=w*m*C+b*S,j=w*m*b-C*S,k=T=>Math.exp(-w*m*T)*(P*Math.sin(S*T)+j*Math.cos(S*T));else if(w===1){v=O=>o-Math.exp(-m*O)*(b+(x+m*b)*O);const T=x+m*b;k=O=>Math.exp(-m*O)*(m*T*O-x)}else{const T=m*Math.sqrt(w*w-1);v=H=>{const Y=Math.exp(-w*m*H),q=Math.min(T*H,300);return o-Y*((x+w*m*b)*Math.sinh(q)+T*b*Math.cosh(q))/T};const O=(x+w*m*b)/T,G=w*m*O-b*T,W=w*m*b-O*T;k=H=>{const Y=Math.exp(-w*m*H),q=Math.min(T*H,300);return Y*(G*Math.sinh(q)+W*Math.cosh(q))}}const M={calculatedDuration:y&&f||null,velocity:T=>at(k(T)),next:T=>{if(!y&&w<1){const G=Math.exp(-w*m*T),W=Math.sin(S*T),H=Math.cos(S*T),Y=o-G*(C*W+b*H),q=at(G*(P*W+j*H));return a.done=Math.abs(q)<=r&&Math.abs(o-Y)<=s,a.value=a.done?o:Y,a}const O=v(T);if(y)a.done=T>=f;else{const G=at(k(T));a.done=Math.abs(G)<=r&&Math.abs(o-O)<=s}return a.value=a.done?o:O,a},toString:()=>{const T=Math.min(nd(M),Mo),O=z0(G=>M.next(T*G).value,T,30);return T+"ms "+O},toTransition:()=>{}};return M}Lo.applyToOptions=e=>{const t=eb(e,100,Lo);return e.ease=t.ease,e.duration=at(t.duration),e.type="keyframes",e};const ab=5;function B0(e,t,n){const r=Math.max(t-ab,0);return Yc(n-e(r),t-r)}function gu({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:s=10,bounceStiffness:i=500,modifyTarget:o,min:a,max:u,restDelta:c=.5,restSpeed:d}){const f=e[0],h={done:!1,value:f},y=j=>a!==void 0&&ju,x=j=>a===void 0?u:u===void 0||Math.abs(a-j)-w*Math.exp(-j/r),v=j=>m+g(j),k=j=>{const M=g(j),T=v(j);h.done=Math.abs(M)<=c,h.value=h.done?m:T};let S,C;const P=j=>{y(h.value)&&(S=j,C=Lo({keyframes:[h.value,x(h.value)],velocity:B0(v,j,h.value),damping:s,stiffness:i,restDelta:c,restSpeed:d}))};return P(0),{calculatedDuration:null,next:j=>{let M=!1;return!C&&S===void 0&&(M=!0,k(j),P(j)),S!==void 0&&j>=S?C.next(j-S):(!M&&k(j),h)}}}function lb(e,t,n){const r=[],s=n||Tn.mix||O0,i=e.length-1;for(let o=0;ot[0];if(i===2&&t[0]===t[1])return()=>t[1];const o=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=lb(t,r,s),u=a.length,c=d=>{if(o&&d1)for(;fc(Mt(e[0],e[i-1],d)):c}function ub(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const s=Vr(0,t,r);e.push(ae(n,1,s))}}function H0(e){const t=[0];return ub(t,e.length-1),t}function cb(e,t){return e.map(n=>n*t)}function db(e,t){return e.map(()=>t||N0).splice(0,e.length-1)}function Ss({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const s=kk(r)?r.map(Yf):Yf(r),i={done:!1,value:t[0]},o=cb(n&&n.length===t.length?n:H0(t),e),a=rd(o,t,{ease:Array.isArray(s)?s:db(t,s)});return{calculatedDuration:e,next:u=>(i.value=a(u),i.done=u>=e,i)}}const fb=e=>e!==null;function ua(e,{repeat:t,repeatType:n="loop"},r,s=1){const i=e.filter(fb),a=s<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||r===void 0?i[a]:r}const hb={decay:gu,inertia:gu,tween:Ss,keyframes:Ss,spring:Lo};function $0(e){typeof e.type=="string"&&(e.type=hb[e.type])}class sd{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const mb=e=>e/100;class qs extends sd{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,s;const{motionValue:n}=this.options;n&&n.updatedAt!==We.now()&&this.tick(We.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(s=(r=this.options).onStop)==null||s.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;$0(t);const{type:n=Ss,repeat:r=0,repeatDelay:s=0,repeatType:i,velocity:o=0}=t;let{keyframes:a}=t;const u=n||Ss;u!==Ss&&typeof a[0]!="number"&&(this.mixKeyframes=ri(mb,O0(a[0],a[1])),a=[0,100]);const c=u({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=u({...t,keyframes:[...a].reverse(),velocity:-o})),c.calculatedDuration===null&&(c.calculatedDuration=nd(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+s,this.totalDuration=this.resolvedDuration*(r+1)-s,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:s,mixKeyframes:i,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:u}=this;if(this.startTime===null)return r.next(0);const{delay:c=0,keyframes:d,repeat:f,repeatType:h,repeatDelay:y,type:x,onUpdate:w,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-s/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const m=this.currentTime-c*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?m<0:m>s;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=s);let v=this.currentTime,k=r;if(f){const j=Math.min(this.currentTime,s)/a;let M=Math.floor(j),T=j%1;!T&&j>=1&&(T=1),T===1&&M--,M=Math.min(M,f+1),!!(M%2)&&(h==="reverse"?(T=1-T,y&&(T-=y/a)):h==="mirror"&&(k=o)),v=Mt(0,1,T)*a}let S;g?(this.delayState.value=d[0],S=this.delayState):S=k.next(v),i&&!g&&(S.value=i(S.value));let{done:C}=S;!g&&u!==null&&(C=this.playbackSpeed>=0?this.currentTime>=s:this.currentTime<=0);const P=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&C);return P&&x!==gu&&(S.value=ua(d,this.options,b,this.speed)),w&&w(S.value),P&&this.finish(),S}then(t,n){return this.finished.then(t,n)}get duration(){return pt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pt(t)}get time(){return pt(this.currentTime)}set time(t){t=at(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return B0(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(We.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=pt(this.currentTime))}play(){var s,i;if(this.isStopped)return;const{driver:t=Jk,startTime:n}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),(i=(s=this.options).onPlay)==null||i.call(s);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(We.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function pb(e){for(let t=1;te*180/Math.PI,yu=e=>{const t=Bn(Math.atan2(e[1],e[0]));return xu(t)},gb={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:yu,rotateZ:yu,skewX:e=>Bn(Math.atan(e[1])),skewY:e=>Bn(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},xu=e=>(e=e%360,e<0&&(e+=360),e),nh=yu,rh=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),sh=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),yb={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:rh,scaleY:sh,scale:e=>(rh(e)+sh(e))/2,rotateX:e=>xu(Bn(Math.atan2(e[6],e[5]))),rotateY:e=>xu(Bn(Math.atan2(-e[2],e[0]))),rotateZ:nh,rotate:nh,skewX:e=>Bn(Math.atan(e[4])),skewY:e=>Bn(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function vu(e){return e.includes("scale")?1:0}function wu(e,t){if(!e||e==="none")return vu(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,s;if(n)r=yb,s=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=gb,s=a}if(!s)return vu(t);const i=r[t],o=s[1].split(",").map(vb);return typeof i=="function"?i(o):o[i]}const xb=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return wu(n,t)};function vb(e){return parseFloat(e.trim())}const Gr=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Kr=new Set([...Gr,"pathRotation"]),ih=e=>e===Wr||e===R,wb=new Set(["x","y","z"]),kb=Gr.filter(e=>!wb.has(e));function bb(e){const t=[];return kb.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const mn={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>wu(t,"x"),y:(e,{transform:t})=>wu(t,"y")};mn.translateX=mn.x;mn.translateY=mn.y;const Un=new Set;let ku=!1,bu=!1,Su=!1;function U0(){if(bu){const e=Array.from(Un).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const s=bb(r);s.length&&(n.set(r,s),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const s=n.get(r);s&&s.forEach(([i,o])=>{var a;(a=r.getValue(i))==null||a.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}bu=!1,ku=!1,Un.forEach(e=>e.complete(Su)),Un.clear()}function W0(){Un.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(bu=!0)})}function Sb(){Su=!0,W0(),U0(),Su=!1}class id{constructor(t,n,r,s,i,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=s,this.element=i,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(Un.add(this),ku||(ku=!0,Z.read(W0),Z.resolveKeyframes(U0))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:s}=this;if(t[0]===null){const i=s==null?void 0:s.get(),o=t[t.length-1];if(i!==void 0)t[0]=i;else if(r&&n){const a=r.readValue(n,o);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=o),s&&i===void 0&&s.set(t[0])}pb(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Un.delete(this)}cancel(){this.state==="scheduled"&&(Un.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const jb=e=>e.startsWith("--");function G0(e,t,n){jb(t)?e.style.setProperty(t,n):e.style[t]=n}const Pb={};function od(e,t){const n=w0(e);return()=>Pb[t]??n()}const ad=od(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),K0=od(()=>window.ViewTimeline!==void 0,"viewTimeline"),q0=od(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),ds=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,oh={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:ds([0,.65,.55,1]),circOut:ds([.55,0,1,.45]),backIn:ds([.31,.01,.66,-.59]),backOut:ds([.33,1.53,.69,.99])};function Y0(e,t){if(e)return typeof e=="function"?q0()?z0(e,t):"ease-out":_0(e)?ds(e):Array.isArray(e)?e.map(n=>Y0(n,t)||oh.easeOut):oh[e]}function Cb(e,t,n,{delay:r=0,duration:s=300,repeat:i=0,repeatType:o="loop",ease:a="easeOut",times:u}={},c=void 0){const d={[t]:n};u&&(d.offset=u);const f=Y0(a,s);Array.isArray(f)&&(d.easing=f);const h={delay:r,duration:s,easing:Array.isArray(f)?"linear":f,fill:"both",iterations:i+1,direction:o==="reverse"?"alternate":"normal"};return c&&(h.pseudoElement=c),e.animate(d,h)}function X0(e){return typeof e=="function"&&"applyToOptions"in e}function Tb({type:e,...t}){return X0(e)&&q0()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Z0 extends sd{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:s,pseudoElement:i,allowFlatten:o=!1,finalKeyframe:a,onComplete:u}=t;this.isPseudoElement=!!i,this.allowFlatten=o,this.options=t,Kc(typeof t.type!="string");const c=Tb(t);this.animation=Cb(n,r,s,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const d=ua(s,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(d),G0(n,r,d),this.animation.cancel()}u==null||u(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,s;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((s=(r=this.animation).commitStyles)==null||s.call(r))}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return pt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+pt(t)}get time(){return pt(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=at(t),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:s}){var i;return this.allowFlatten&&((i=this.animation.effect)==null||i.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&ad()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),tt):s(this)}}const Q0={anticipate:C0,backInOut:P0,circInOut:E0};function Eb(e){return e in Q0}function Nb(e){typeof e.ease=="string"&&Eb(e.ease)&&(e.ease=Q0[e.ease])}const Ya=10;class _b extends Z0{constructor(t){Nb(t),$0(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:s,element:i,...o}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new qs({...o,autoplay:!1}),u=Math.max(Ya,We.now()-this.startTime),c=Mt(0,Ya,u-Ya),d=a.sample(u).value,{name:f}=this.options;i&&f&&G0(i,f,d),n.setWithVelocity(a.sample(Math.max(0,u-c)).value,d,c),a.stop()}}const ah=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Nt.test(e)||e==="0")&&!e.startsWith("url("));function Mb(e){const t=e[0];if(e.length===1)return!0;for(let n=0;nObject.hasOwnProperty.call(Element.prototype,"animate"));function Vb(e){var f;const{motionValue:t,name:n,repeatDelay:r,repeatType:s,damping:i,type:o,keyframes:a}=e;if(!(((f=t==null?void 0:t.owner)==null?void 0:f.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:d}=t.owner.getProps();return Ib()&&n&&(J0.has(n)||Rb.has(n)&&Db(a))&&(n!=="transform"||!d)&&!c&&!r&&s!=="mirror"&&i!==0&&o!=="inertia"}const Fb=40;class Ob extends sd{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:o="loop",keyframes:a,name:u,motionValue:c,element:d,...f}){var x;super(),this.stop=()=>{var w,b;this._animation&&(this._animation.stop(),(w=this.stopTimeline)==null||w.call(this)),(b=this.keyframeResolver)==null||b.cancel()},this.createdAt=We.now();const h={autoplay:t,delay:n,type:r,repeat:s,repeatDelay:i,repeatType:o,name:u,motionValue:c,element:d,...f},y=(d==null?void 0:d.KeyframeResolver)||id;this.keyframeResolver=new y(a,(w,b,m)=>this.onKeyframesResolved(w,b,h,!m),u,c,d),(x=this.keyframeResolver)==null||x.scheduleResolve()}onKeyframesResolved(t,n,r,s){var m,g;this.keyframeResolver=void 0;const{name:i,type:o,velocity:a,delay:u,isHandoff:c,onUpdate:d}=r;this.resolvedAt=We.now();let f=!0;Lb(t,i,o,a)||(f=!1,(Tn.instantAnimations||!u)&&(d==null||d(ua(t,r,n))),t[0]=t[t.length-1],ju(r),r.repeat=0);const y={startTime:s?this.resolvedAt?this.resolvedAt-this.createdAt>Fb?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},x=f&&!c&&Vb(y),w=(g=(m=y.motionValue)==null?void 0:m.owner)==null?void 0:g.current;let b;if(x)try{b=new _b({...y,element:w})}catch{b=new qs(y)}else b=new qs(y);b.finished.then(()=>{this.notifyFinished()}).catch(tt),this.pendingTimeline&&(this.stopTimeline=b.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=b}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),Sb()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}function ey(e,t,n,r=0,s=1){const i=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),o=e.size,a=(o-1)*r;return typeof n=="function"?n(i,o):s===1?i*r:a-i*r}const lh=30,zb=e=>!isNaN(parseFloat(e)),js={current:void 0};class Bb{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var i;const s=We.now();if(this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((i=this.events.change)==null||i.notify(this.current),this.dependents))for(const o of this.dependents)o.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=We.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=zb(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new qc);const r=this.events[t].add(n);return t==="change"?()=>{r(),Z.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return js.current&&js.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=We.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>lh)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,lh);return Yc(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Ct(e,t){return new Bb(e,t)}function ld(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function ud(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?ld(n,e):n}const Hb={type:"spring",stiffness:500,damping:25,restSpeed:10},$b=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Ub={type:"keyframes",duration:.8},Wb={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Gb=(e,{keyframes:t})=>t.length>2?Ub:Kr.has(e)?e.startsWith("scale")?$b(t[1]):Hb:Wb,Kb=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function qb(e){for(const t in e)if(!Kb.has(t))return!0;return!1}const cd=(e,t,n,r={},s,i)=>o=>{const a=ud(r,e)||{},u=a.delay||r.delay||0;let{elapsed:c=0}=r;c=c-at(u);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:s};qb(a)||Object.assign(d,Gb(e,d)),d.duration&&(d.duration=at(d.duration)),d.repeatDelay&&(d.repeatDelay=at(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let f=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(ju(d),d.delay===0&&(f=!0)),(Tn.instantAnimations||Tn.skipAnimations||s!=null&&s.shouldSkipAnimations||a.skipAnimations)&&(f=!0,ju(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,f&&!i&&t.get()!==void 0){const h=ua(d.keyframes,a);if(h!==void 0){Z.update(()=>{d.onUpdate(h),d.onComplete()});return}}return a.isSync?new qs(d):new Ob(d)},Yb=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Xb(e){const t=Yb.exec(e);if(!t)return[,];const[,n,r,s]=t;return[`--${n??r}`,s]}function ty(e,t,n=1){const[r,s]=Xb(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const o=i.trim();return y0(o)?parseFloat(o):o}return Qc(s)?ty(s,t,n+1):s}function uh(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function dd(e,t,n,r){if(typeof t=="function"){const[s,i]=uh(r);t=t(n!==void 0?n:e.custom,s,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[s,i]=uh(r);t=t(n!==void 0?n:e.custom,s,i)}return t}function Wn(e,t,n){const r=e.getProps();return dd(r,t,n!==void 0?n:r.custom,e)}const ny=new Set(["width","height","top","left","right","bottom",...Gr]),Pu=e=>Array.isArray(e);function Zb(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Ct(n))}function Qb(e){return Pu(e)?e[e.length-1]||0:e}function Jb(e,t){const n=Wn(e,t);let{transitionEnd:r={},transition:s={},...i}=n||{};i={...i,...r};for(const o in i){const a=Qb(i[o]);Zb(e,o,a)}}const _e=e=>!!(e&&e.getVelocity);function eS(e){return!!(_e(e)&&e.add)}function Cu(e,t){const n=e.getValue("willChange");if(eS(n))return n.add(t);if(!n&&Tn.WillChange){const r=new Tn.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function fd(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const tS="framerAppearId",ry="data-"+fd(tS);function sy(e){return e.props[ry]}function nS({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function iy(e,t,{delay:n=0,transitionOverride:r,type:s}={}){let{transition:i,transitionEnd:o,...a}=t;const u=e.getDefaultTransition();i=i?ld(i,u):u;const c=i==null?void 0:i.reduceMotion,d=i==null?void 0:i.skipAnimations;r&&(i=r);const f=[],h=s&&e.animationState&&e.animationState.getState()[s],y=i==null?void 0:i.path;y&&y.animateVisualElement(e,a,i,n,f);for(const x in a){const w=e.getValue(x,e.latestValues[x]??null),b=a[x];if(b===void 0||h&&nS(h,x))continue;const m={delay:n,...ud(i||{},x)};d&&(m.skipAnimations=!0);const g=w.get();if(g!==void 0&&!w.isAnimating()&&!Array.isArray(b)&&b===g&&!m.velocity){Z.update(()=>w.set(b));continue}let v=!1;if(window.MotionHandoffAnimation){const C=sy(e);if(C){const P=window.MotionHandoffAnimation(C,x,Z);P!==null&&(m.startTime=P,v=!0)}}Cu(e,x);const k=c??e.shouldReduceMotion;w.start(cd(x,w,b,k&&ny.has(x)?{type:!1}:m,e,v));const S=w.animation;S&&f.push(S)}if(o){const x=()=>Z.update(()=>{o&&Jb(e,o)});f.length?Promise.all(f).then(x):x()}return f}function Tu(e,t,n={}){var u;const r=Wn(e,t,n.type==="exit"?(u=e.presenceContext)==null?void 0:u.custom:void 0);let{transition:s=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(s=n.transitionOverride);const i=r?()=>Promise.all(iy(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:d=0,staggerChildren:f,staggerDirection:h}=s;return rS(e,t,c,d,f,h,n)}:()=>Promise.resolve(),{when:a}=s;if(a){const[c,d]=a==="beforeChildren"?[i,o]:[o,i];return c().then(()=>d())}else return Promise.all([i(),o(n.delay)])}function rS(e,t,n=0,r=0,s=0,i=1,o){const a=[];for(const u of e.variantChildren)u.notify("AnimationStart",t),a.push(Tu(u,t,{...o,delay:n+(typeof r=="function"?0:r)+ey(e.variantChildren,u,r,s,i)}).then(()=>u.notify("AnimationComplete",t)));return Promise.all(a)}function sS(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const s=t.map(i=>Tu(e,i,n));r=Promise.all(s)}else if(typeof t=="string")r=Tu(e,t,n);else{const s=typeof t=="function"?Wn(e,t,n.custom):t;r=Promise.all(iy(e,s,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const iS={test:e=>e==="auto",parse:e=>e},oy=e=>t=>t.test(e),ay=[Wr,R,zt,Ht,Dk,Ak,iS],ch=e=>ay.find(oy(e));function oS(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||v0(e):!0}const aS=new Set(["brightness","contrast","saturate","opacity"]);function lS(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Jc)||[];if(!r)return e;const s=n.replace(r,"");let i=aS.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+s+")"}const uS=/\b([a-z-]*)\(.*?\)/gu,Eu={...Nt,getAnimatableNone:e=>{const t=e.match(uS);return t?t.map(lS).join(" "):e}},Nu={...Nt,getAnimatableNone:e=>{const t=Nt.parse(e);return Nt.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},dh={...Wr,transform:Math.round},cS={rotate:Ht,pathRotation:Ht,rotateX:Ht,rotateY:Ht,rotateZ:Ht,scale:Ti,scaleX:Ti,scaleY:Ti,scaleZ:Ti,skew:Ht,skewX:Ht,skewY:Ht,distance:R,translateX:R,translateY:R,translateZ:R,x:R,y:R,z:R,perspective:R,transformPerspective:R,opacity:Ks,originX:Zf,originY:Zf,originZ:R},Ao={borderWidth:R,borderTopWidth:R,borderRightWidth:R,borderBottomWidth:R,borderLeftWidth:R,borderRadius:R,borderTopLeftRadius:R,borderTopRightRadius:R,borderBottomRightRadius:R,borderBottomLeftRadius:R,width:R,maxWidth:R,height:R,maxHeight:R,top:R,right:R,bottom:R,left:R,inset:R,insetBlock:R,insetBlockStart:R,insetBlockEnd:R,insetInline:R,insetInlineStart:R,insetInlineEnd:R,padding:R,paddingTop:R,paddingRight:R,paddingBottom:R,paddingLeft:R,paddingBlock:R,paddingBlockStart:R,paddingBlockEnd:R,paddingInline:R,paddingInlineStart:R,paddingInlineEnd:R,margin:R,marginTop:R,marginRight:R,marginBottom:R,marginLeft:R,marginBlock:R,marginBlockStart:R,marginBlockEnd:R,marginInline:R,marginInlineStart:R,marginInlineEnd:R,fontSize:R,backgroundPositionX:R,backgroundPositionY:R,...cS,zIndex:dh,fillOpacity:Ks,strokeOpacity:Ks,numOctaves:dh},dS={...Ao,color:Pe,backgroundColor:Pe,outlineColor:Pe,fill:Pe,stroke:Pe,borderColor:Pe,borderTopColor:Pe,borderRightColor:Pe,borderBottomColor:Pe,borderLeftColor:Pe,filter:Eu,WebkitFilter:Eu,mask:Nu,WebkitMask:Nu},ly=e=>dS[e],fS=new Set([Eu,Nu]);function uy(e,t){let n=ly(e);return fS.has(n)||(n=Nt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const hS=new Set(["auto","none","0"]);function mS(e,t,n){let r=0,s;for(;r{t.getValue(u).set(c)}),this.resolveNoneKeyframes()}}const hd=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function cy(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){const s=document.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e).filter(r=>r!=null)}const _u=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Ps(e){return x0(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:Or,cancel:dy}=M0(queueMicrotask,!1),bt={x:!1,y:!1};function fy(){return bt.x||bt.y}function gS(e){return e==="x"||e==="y"?bt[e]?null:(bt[e]=!0,()=>{bt[e]=!1}):bt.x||bt.y?null:(bt.x=bt.y=!0,()=>{bt.x=bt.y=!1})}function hy(e,t){const n=cy(e),r=new AbortController,s={passive:!0,...t,signal:r.signal};return[n,s,()=>r.abort()]}function yS(e){return!(e.pointerType==="touch"||fy())}function xS(e,t,n={}){const[r,s,i]=hy(e,n);return r.forEach(o=>{let a=!1,u=!1,c;const d=()=>{o.removeEventListener("pointerleave",x)},f=b=>{c&&(c(b),c=void 0),d()},h=b=>{a=!1,window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",h),u&&(u=!1,f(b))},y=()=>{a=!0,window.addEventListener("pointerup",h,s),window.addEventListener("pointercancel",h,s)},x=b=>{if(b.pointerType!=="touch"){if(a){u=!0;return}f(b)}},w=b=>{if(!yS(b))return;u=!1;const m=t(o,b);typeof m=="function"&&(c=m,o.addEventListener("pointerleave",x,s))};o.addEventListener("pointerenter",w,s),o.addEventListener("pointerdown",y,s)}),i}const my=(e,t)=>t?e===t?!0:my(e,t.parentElement):!1,md=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,vS=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function wS(e){return vS.has(e.tagName)||e.isContentEditable===!0}const kS=new Set(["INPUT","SELECT","TEXTAREA"]);function bS(e){return kS.has(e.tagName)||e.isContentEditable===!0}const Ki=new WeakSet;function fh(e){return t=>{t.key==="Enter"&&e(t)}}function Xa(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const SS=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=fh(()=>{if(Ki.has(n))return;Xa(n,"down");const s=fh(()=>{Xa(n,"up")}),i=()=>Xa(n,"cancel");n.addEventListener("keyup",s,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function hh(e){return md(e)&&!fy()}const mh=new WeakSet;function jS(e,t,n={}){const[r,s,i]=hy(e,n),o=a=>{const u=a.currentTarget;if(!hh(a)||mh.has(a))return;Ki.add(u),n.stopPropagation&&mh.add(a);const c=t(u,a),d={...s,capture:!0},f=(x,w)=>{window.removeEventListener("pointerup",h,d),window.removeEventListener("pointercancel",y,d),Ki.has(u)&&Ki.delete(u),hh(x)&&typeof c=="function"&&c(x,{success:w})},h=x=>{f(x,u===window||u===document||n.useGlobalTarget||my(u,x.target))},y=x=>{f(x,!1)};window.addEventListener("pointerup",h,d),window.addEventListener("pointercancel",y,d)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,s),Ps(a)&&(a.addEventListener("focus",c=>SS(c,s)),!wS(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function pd(e){return x0(e)&&"ownerSVGElement"in e}const qi=new WeakMap;let sn;const py=(e,t,n)=>(r,s)=>s&&s[0]?s[0][e+"Size"]:pd(r)&&"getBBox"in r?r.getBBox()[t]:r[n],PS=py("inline","width","offsetWidth"),CS=py("block","height","offsetHeight");function TS({target:e,borderBoxSize:t}){var n;(n=qi.get(e))==null||n.forEach(r=>{r(e,{get width(){return PS(e,t)},get height(){return CS(e,t)}})})}function ES(e){e.forEach(TS)}function NS(){typeof ResizeObserver>"u"||(sn=new ResizeObserver(ES))}function _S(e,t){sn||NS();const n=cy(e);return n.forEach(r=>{let s=qi.get(r);s||(s=new Set,qi.set(r,s)),s.add(t),sn==null||sn.observe(r)}),()=>{n.forEach(r=>{const s=qi.get(r);s==null||s.delete(t),s!=null&&s.size||sn==null||sn.unobserve(r)})}}const Yi=new Set;let wr;function MS(){wr=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};Yi.forEach(t=>t(e))},window.addEventListener("resize",wr)}function LS(e){return Yi.add(e),wr||MS(),()=>{Yi.delete(e),!Yi.size&&typeof wr=="function"&&(window.removeEventListener("resize",wr),wr=void 0)}}function Mu(e,t){return typeof e=="function"?LS(e):_S(e,t)}function gy(e,t){let n;const r=()=>{const{currentTime:s}=t,o=(s===null?0:s.value)/100;n!==o&&e(o),n=o};return Z.preUpdate(r,!0),()=>vt(r)}function AS(e){return pd(e)&&e.tagName==="svg"}function DS(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],s=e[1+n],i=e[2+n],o=e[3+n],a=rd(s,i,o);return t?a(r):a}function RS(e,t,n={}){const r=e.get();let s=null,i=r,o;const a=typeof r=="string"?r.replace(/[\d.-]/g,""):void 0,u=()=>{s&&(s.stop(),s=null),e.animation=void 0},c=()=>{const f=ph(e.get()),h=ph(i);if(f===h){u();return}const y=s?s.getGeneratorVelocity():e.getVelocity();u(),s=new qs({keyframes:[f,h],velocity:y,type:"spring",restDelta:.001,restSpeed:.01,...n,onUpdate:o})},d=()=>{var f;c(),e.animation=s??void 0,(f=e.events.animationStart)==null||f.notify(),s==null||s.then(()=>{var h;e.animation=void 0,(h=e.events.animationComplete)==null||h.notify()})};if(e.attach((f,h)=>{i=f,o=y=>h(Za(y,a)),Z.postRender(d)},u),_e(t)){let f=n.skipInitialAnimation===!0;const h=t.on("change",x=>{f?(f=!1,e.jump(Za(x,a),!1)):e.set(Za(x,a))}),y=e.on("destroy",h);return()=>{h(),y()}}return u}function Za(e,t){return t?e+t:e}function ph(e){return typeof e=="number"?e:parseFloat(e)}const IS=[...ay,Pe,Nt],VS=e=>IS.find(oy(e)),gh=()=>({translate:0,scale:1,origin:0,originPoint:0}),kr=()=>({x:gh(),y:gh()}),yh=()=>({min:0,max:0}),Te=()=>({x:yh(),y:yh()}),FS=new WeakMap;function ca(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Ys(e){return typeof e=="string"||Array.isArray(e)}const gd=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],yd=["initial",...gd];function da(e){return ca(e.animate)||yd.some(t=>Ys(e[t]))}function yy(e){return!!(da(e)||e.variants)}function OS(e,t,n){for(const r in t){const s=t[r],i=n[r];if(_e(s))e.addValue(r,s);else if(_e(i))e.addValue(r,Ct(s,{owner:e}));else if(i!==s)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(s):o.hasAnimated||o.set(s)}else{const o=e.getStaticValue(r);e.addValue(r,Ct(o!==void 0?o:s,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const Do={current:null},xd={current:!1},zS=typeof window<"u";function xy(){if(xd.current=!0,!!zS)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Do.current=e.matches;e.addEventListener("change",t),t()}else Do.current=!1}const xh=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let Ro={};function vy(e){Ro=e}function BS(){return Ro}class HS{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:s,skipAnimations:i,blockInitialAnimation:o,visualState:a},u={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=id,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const y=We.now();this.renderScheduledAtthis.bindToMotionValue(i,s)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(xd.current||xy(),this.shouldReduceMotion=Do.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),vt(this.notifyUpdate),vt(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&J0.has(t)&&this.current instanceof HTMLElement){const{factory:o,keyframes:a,times:u,ease:c,duration:d}=n.accelerate,f=new Z0({element:this.current,name:t,keyframes:a,times:u,ease:c,duration:at(d)}),h=o(f);this.valueSubscriptions.set(t,()=>{h(),f.cancel()});return}const r=Kr.has(t);r&&this.onBindTransform&&this.onBindTransform();const s=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&Z.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{s(),i&&i()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ro){const n=Ro[t];if(!n)continue;const{isEnabled:r,Feature:s}=n;if(!this.features[t]&&s&&r(this.props)&&(this.features[t]=new s(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Te()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;rn.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Ct(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(y0(r)||v0(r))?r=parseFloat(r):!VS(r)&&Nt.test(n)&&(r=uy(t,n)),this.setBaseTarget(t,_e(r)?r.get():r)),_e(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var i;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const o=dd(this.props,n,(i=this.presenceContext)==null?void 0:i.custom);o&&(r=o[t])}if(n&&r!==void 0)return r;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!_e(s)?s:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new qc),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Or.render(this.render)}}class wy extends HS{constructor(){super(...arguments),this.KeyframeResolver=pS}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;_e(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Mn{constructor(t){this.isMounted=!1,this.node=t}update(){}}function ky({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function $S({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function US(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Qa(e){return e===void 0||e===1}function Lu({scale:e,scaleX:t,scaleY:n}){return!Qa(e)||!Qa(t)||!Qa(n)}function In(e){return Lu(e)||by(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function by(e){return vh(e.x)||vh(e.y)}function vh(e){return e&&e!=="0%"}function Io(e,t,n){const r=e-n,s=t*r;return n+s}function wh(e,t,n,r,s){return s!==void 0&&(e=Io(e,s,r)),Io(e,n,r)+t}function Au(e,t=0,n=1,r,s){e.min=wh(e.min,t,n,r,s),e.max=wh(e.max,t,n,r,s)}function Sy(e,{x:t,y:n}){Au(e.x,t.translate,t.scale,t.originPoint),Au(e.y,n.translate,n.scale,n.originPoint)}const kh=.999999999999,bh=1.0000000000001;function WS(e,t,n,r=!1){var a;const s=n.length;if(!s)return;t.x=t.y=1;let i,o;for(let u=0;ukh&&(t.x=1),t.ykh&&(t.y=1)}function It(e,t){e.min+=t,e.max+=t}function Sh(e,t,n,r,s=.5){const i=ae(e.min,e.max,s);Au(e,t,n,i,r)}function jh(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function Xi(e,t,n){const r=n??e;Sh(e.x,jh(t.x,r.x),t.scaleX,t.scale,t.originX),Sh(e.y,jh(t.y,r.y),t.scaleY,t.scale,t.originY)}function jy(e,t){return ky(US(e.getBoundingClientRect(),t))}function GS(e,t,n){const r=jy(e,n),{scroll:s}=t;return s&&(It(r.x,s.offset.x),It(r.y,s.offset.y)),r}const KS={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},qS=Gr.length;function YS(e,t,n){let r="",s=!0;for(let o=0;o{if(!t.target)return e;if(typeof e=="string")if(R.test(e))e=parseFloat(e);else return e;const n=Ph(e,t.target.x),r=Ph(e,t.target.y);return`${n}% ${r}%`}},XS={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,s=Nt.parse(e);if(s.length>5)return r;const i=Nt.createTransformer(e),o=typeof s[0]!="number"?1:0,a=n.x.scale*t.x,u=n.y.scale*t.y;s[0+o]/=a,s[1+o]/=u;const c=ae(a,u,.5);return typeof s[2+o]=="number"&&(s[2+o]/=c),typeof s[3+o]=="number"&&(s[3+o]/=c),i(s)}},Du={borderRadius:{...ss,applyTo:[...hd]},borderTopLeftRadius:ss,borderTopRightRadius:ss,borderBottomLeftRadius:ss,borderBottomRightRadius:ss,boxShadow:XS};function Cy(e,{layout:t,layoutId:n}){return Kr.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Du[e]||e==="opacity")}function wd(e,t,n){var o;const r=e.style,s=t==null?void 0:t.style,i={};if(!r)return i;for(const a in r)(_e(r[a])||s&&_e(s[a])||Cy(a,e)||((o=n==null?void 0:n.getValue(a))==null?void 0:o.liveStyle)!==void 0)&&(i[a]=r[a]);return i}function ZS(e){return window.getComputedStyle(e)}class QS extends wy{constructor(){super(...arguments),this.type="html",this.renderInstance=Py}readValueFromInstance(t,n){var r;if(Kr.has(n))return(r=this.projection)!=null&&r.isProjecting?vu(n):xb(t,n);{const s=ZS(t),i=(A0(n)?s.getPropertyValue(n):s[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return jy(t,n)}build(t,n,r){vd(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return wd(t,n,r)}}const JS={offset:"stroke-dashoffset",array:"stroke-dasharray"},e2={offset:"strokeDashoffset",array:"strokeDasharray"};function t2(e,t,n=1,r=0,s=!0){e.pathLength=1;const i=s?JS:e2;e[i.offset]=`${-r}`,e[i.array]=`${t} ${n}`}const n2=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function Ty(e,{attrX:t,attrY:n,attrScale:r,pathLength:s,pathSpacing:i=1,pathOffset:o=0,...a},u,c,d){if(vd(e,a,c),u){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:f,style:h}=e;f.transform&&(h.transform=f.transform,delete f.transform),(h.transform||f.transformOrigin)&&(h.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),h.transform&&(h.transformBox=(d==null?void 0:d.transformBox)??"fill-box",delete f.transformBox);for(const y of n2)f[y]!==void 0&&(h[y]=f[y],delete f[y]);t!==void 0&&(f.x=t),n!==void 0&&(f.y=n),r!==void 0&&(f.scale=r),s!==void 0&&t2(f,s,i,o,!1)}const Ey=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),Ny=e=>typeof e=="string"&&e.toLowerCase()==="svg";function r2(e,t,n,r){Py(e,t,void 0,r);for(const s in t.attrs)e.setAttribute(Ey.has(s)?s:fd(s),t.attrs[s])}function _y(e,t,n){const r=wd(e,t,n);for(const s in e)if(_e(e[s])||_e(t[s])){const i=Gr.indexOf(s)!==-1?"attr"+s.charAt(0).toUpperCase()+s.substring(1):s;r[i]=e[s]}return r}class s2 extends wy{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Te}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Kr.has(n)){const r=ly(n);return r&&r.default||0}return n=Ey.has(n)?n:fd(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return _y(t,n,r)}build(t,n,r){Ty(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,s){r2(t,n,r,s)}mount(t){this.isSVGTag=Ny(t.tagName),super.mount(t)}}const i2=yd.length;function My(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?My(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;nPromise.all(t.map(({animation:n,options:r})=>sS(e,n,r)))}function u2(e){let t=l2(e),n=Ch(),r=!0,s=!1;const i=c=>(d,f)=>{var y;const h=Wn(e,f,c==="exit"?(y=e.presenceContext)==null?void 0:y.custom:void 0);if(h){const{transition:x,transitionEnd:w,...b}=h;d={...d,...b,...w}}return d};function o(c){t=c(e)}function a(c){const{props:d}=e,f=My(e.parent)||{},h=[],y=new Set;let x={},w=1/0;for(let m=0;mw&&S,T=!1;const O=Array.isArray(k)?k:[k];let G=O.reduce(i(g),{});C===!1&&(G={});const{prevResolvedValues:W={}}=v,H={...W,...G},Y=N=>{M=!0,y.has(N)&&(T=!0,y.delete(N)),v.needsAnimating[N]=!0;const L=e.getValue(N);L&&(L.liveStyle=!1)};for(const N in H){const L=G[N],F=W[N];if(x.hasOwnProperty(N))continue;let E=!1;Pu(L)&&Pu(F)?E=!Ly(L,F)||j:E=L!==F,E?L!=null?Y(N):y.add(N):L!==void 0&&y.has(N)?Y(N):v.protectedKeys[N]=!0}v.prevProp=k,v.prevResolvedValues=G,v.isActive&&(x={...x,...G}),(r||s)&&e.blockInitialAnimation&&(M=!1);const q=P&&j;M&&(!q||T)&&h.push(...O.map(N=>{const L={type:g};if(typeof N=="string"&&(r||s)&&!q&&e.manuallyAnimateOnMount&&e.parent){const{parent:F}=e,E=Wn(F,N);if(F.enteringChildren&&E){const{delayChildren:A}=E.transition||{};L.delay=ey(F.enteringChildren,e,A)}}return{animation:N,options:L}}))}if(y.size){const m={};if(typeof d.initial!="boolean"){const g=Wn(e,Array.isArray(d.initial)?d.initial[0]:d.initial);g&&g.transition&&(m.transition=g.transition)}y.forEach(g=>{const v=e.getBaseTarget(g),k=e.getValue(g);k&&(k.liveStyle=!0),m[g]=v??null}),h.push({animation:m})}let b=!!h.length;return r&&(d.initial===!1||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(b=!1),r=!1,s=!1,b?t(h):Promise.resolve()}function u(c,d){var h;if(n[c].isActive===d)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(y=>{var x;return(x=y.animationState)==null?void 0:x.setActive(c,d)}),n[c].isActive=d;const f=a(c);for(const y in n)n[y].protectedKeys={};return f}return{animateChanges:a,setActive:u,setAnimateFunction:o,getState:()=>n,reset:()=>{n=Ch(),s=!0}}}function c2(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Ly(t,e):!1}function An(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Ch(){return{animate:An(!0),whileInView:An(),whileHover:An(),whileTap:An(),whileDrag:An(),whileFocus:An(),exit:An()}}function Ru(e,t){e.min=t.min,e.max=t.max}function kt(e,t){Ru(e.x,t.x),Ru(e.y,t.y)}function Th(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const Ay=1e-4,d2=1-Ay,f2=1+Ay,Dy=.01,h2=0-Dy,m2=0+Dy;function Ge(e){return e.max-e.min}function p2(e,t,n){return Math.abs(e-t)<=n}function Eh(e,t,n,r=.5){e.origin=r,e.originPoint=ae(t.min,t.max,e.origin),e.scale=Ge(n)/Ge(t),e.translate=ae(n.min,n.max,e.origin)-e.originPoint,(e.scale>=d2&&e.scale<=f2||isNaN(e.scale))&&(e.scale=1),(e.translate>=h2&&e.translate<=m2||isNaN(e.translate))&&(e.translate=0)}function Cs(e,t,n,r){Eh(e.x,t.x,n.x,r?r.originX:void 0),Eh(e.y,t.y,n.y,r?r.originY:void 0)}function Nh(e,t,n,r=0){const s=r?ae(n.min,n.max,r):n.min;e.min=s+t.min,e.max=e.min+Ge(t)}function g2(e,t,n,r){Nh(e.x,t.x,n.x,r==null?void 0:r.x),Nh(e.y,t.y,n.y,r==null?void 0:r.y)}function _h(e,t,n,r=0){const s=r?ae(n.min,n.max,r):n.min;e.min=t.min-s,e.max=e.min+Ge(t)}function Vo(e,t,n,r){_h(e.x,t.x,n.x,r==null?void 0:r.x),_h(e.y,t.y,n.y,r==null?void 0:r.y)}function Mh(e,t,n,r,s){return e-=t,e=Io(e,1/n,r),s!==void 0&&(e=Io(e,1/s,r)),e}function y2(e,t=0,n=1,r=.5,s,i=e,o=e){if(zt.test(t)&&(t=parseFloat(t),t=ae(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=ae(i.min,i.max,r);e===i&&(a-=t),e.min=Mh(e.min,t,n,a,s),e.max=Mh(e.max,t,n,a,s)}function Lh(e,t,[n,r,s],i,o){y2(e,t[n],t[r],t[s],t.scale,i,o)}const x2=["x","scaleX","originX"],v2=["y","scaleY","originY"];function Ah(e,t,n,r){Lh(e.x,t,x2,n?n.x:void 0,r?r.x:void 0),Lh(e.y,t,v2,n?n.y:void 0,r?r.y:void 0)}function Dh(e){return e.translate===0&&e.scale===1}function Ry(e){return Dh(e.x)&&Dh(e.y)}function Rh(e,t){return e.min===t.min&&e.max===t.max}function w2(e,t){return Rh(e.x,t.x)&&Rh(e.y,t.y)}function Ih(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Iy(e,t){return Ih(e.x,t.x)&&Ih(e.y,t.y)}function Vh(e){return Ge(e.x)/Ge(e.y)}function Fh(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Rt(e){return[e("x"),e("y")]}function k2(e,t,n){let r="";const s=e.x.translate/t.x,i=e.y.translate/t.y,o=(n==null?void 0:n.z)||0;if((s||i||o)&&(r=`translate3d(${s}px, ${i}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,pathRotation:f,rotateX:h,rotateY:y,skewX:x,skewY:w}=n;c&&(r=`perspective(${c}px) ${r}`),d&&(r+=`rotate(${d}deg) `),f&&(r+=`rotate(${f}deg) `),h&&(r+=`rotateX(${h}deg) `),y&&(r+=`rotateY(${y}deg) `),x&&(r+=`skewX(${x}deg) `),w&&(r+=`skewY(${w}deg) `)}const a=e.x.scale*t.x,u=e.y.scale*t.y;return(a!==1||u!==1)&&(r+=`scale(${a}, ${u})`),r||"none"}const b2=hd.length,Oh=e=>typeof e=="string"?parseFloat(e):e,zh=e=>typeof e=="number"||R.test(e);function S2(e,t,n,r,s,i){s?(e.opacity=ae(0,n.opacity??1,j2(r)),e.opacityExit=ae(t.opacity??1,0,P2(r))):i&&(e.opacity=ae(t.opacity??1,n.opacity??1,r));for(let o=0;ort?1:n(Vr(e,t,r))}function C2(e,t,n){const r=_e(e)?e:Ct(e);return r.start(cd("",r,t,n)),r.animation}function Xs(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}const T2=(e,t)=>e.depth-t.depth;class E2{constructor(){this.children=[],this.isDirty=!1}add(t){Gc(this.children,t),this.isDirty=!0}remove(t){No(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(T2),this.isDirty=!1,this.children.forEach(t)}}function N2(e,t){const n=We.now(),r=({timestamp:s})=>{const i=s-n;i>=t&&(vt(r),e(i-t))};return Z.setup(r,!0),()=>vt(r)}function Zi(e){return _e(e)?e.get():e}class _2{constructor(){this.members=[]}add(t){Gc(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const s=r.instance;(!s||s.isConnected===!1)&&!r.snapshot&&(No(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(No(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const s=this.members[r];if(s.isPresent!==!1&&((n=s.instance)==null?void 0:n.isConnected)!==!1)return this.promote(s),!0}return!1}promote(t,n){var s;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:i}=r.options,{layoutDependency:o}=t.options;(i===void 0||i!==o)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(s=t.root)!=null&&s.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,s,i,o;(r=(n=t.options).onExitComplete)==null||r.call(n),(o=(s=t.resumingFrom)==null?void 0:(i=s.options).onExitComplete)==null||o.call(i)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const Qi={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Ja=["","X","Y","Z"],M2=1e3;let L2=0;function el(e,t,n,r){const{latestValues:s}=t;s[e]&&(n[e]=s[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Fy(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=sy(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:s,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Z,!(s||i))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Fy(r)}function Oy({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:s}){return class{constructor(o={},a=t==null?void 0:t()){this.id=L2++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(R2),this.nodes.forEach(B2),this.nodes.forEach(H2),this.nodes.forEach(I2)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let u=0;uthis.root.updateBlockedByResize=!1;Z.read(()=>{f=window.innerWidth}),e(o,()=>{const y=window.innerWidth;y!==f&&(f=y,this.root.updateBlockedByResize=!0,d&&d(),d=N2(h,250),Qi.hasAnimatedSinceResize&&(Qi.hasAnimatedSinceResize=!1,this.nodes.forEach(Uh)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||u)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeLayoutChanged:h,layout:y})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const x=this.options.transition||c.getDefaultTransition()||K2,{onLayoutAnimationStart:w,onLayoutAnimationComplete:b}=c.getProps(),m=!this.targetLayout||!Iy(this.targetLayout,y),g=!f&&h;if(this.options.layoutRoot||this.resumeFrom||g||f&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const v={...ud(x,"layout"),onPlay:w,onComplete:b};(c.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v),this.setAnimationOrigin(d,g,v.path)}else f||Uh(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=y})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),vt(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach($2),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Fy(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ge(this.snapshot.measuredBox.x)&&!Ge(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u{const P=C/1e3,j=S==null?void 0:S(P);j?(h.x.translate=j.x,h.x.scale=ae(o.x.scale,1,P),h.x.origin=o.x.origin,h.x.originPoint=o.x.originPoint,h.y.translate=j.y,h.y.scale=ae(o.y.scale,1,P),h.y.origin=o.y.origin,h.y.originPoint=o.y.originPoint):(Wh(h.x,o.x,P),Wh(h.y,o.y,P)),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Vo(y,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),W2(this.relativeTarget,this.relativeTargetOrigin,y,P),k&&w2(this.relativeTarget,k)&&(this.isProjectionDirty=!1),k||(k=Te()),kt(k,this.relativeTarget)),b&&(this.animationValues=f,S2(f,d,this.latestValues,P,v,g)),j&&j.rotate!==void 0&&(this.animationValues||(this.animationValues=f),this.animationValues.pathRotation=j.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){var a,u,c;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(c=(u=this.resumingFrom)==null?void 0:u.currentAnimation)==null||c.stop(),this.pendingAnimation&&(vt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Z.update(()=>{Qi.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Ct(0)),this.motionValue.jump(0,!1),this.currentAnimation=C2(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:d=>{this.mixTargetDelta(d),o.onUpdate&&o.onUpdate(d)},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(M2),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:u,layout:c,latestValues:d}=o;if(!(!a||!u||!c)){if(this!==o&&this.layout&&c&&zy(this.options.animationType,this.layout.layoutBox,c.layoutBox)){u=this.target||Te();const f=Ge(this.layout.layoutBox.x);u.x.min=o.target.x.min,u.x.max=u.x.min+f;const h=Ge(this.layout.layoutBox.y);u.y.min=o.target.y.min,u.y.max=u.y.min+h}kt(a,u),Xi(a,d),Cs(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new _2),this.sharedNodes.get(o).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var a;const{layoutId:o}=this.options;return o?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:o}=this.options;return o?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:u}={}){const c=this.getStack();c&&c.promote(this,u),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:u}=o;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(a=!0),!a)return;const c={};u.z&&el("z",o,c,this.animationValues);for(let d=0;d{var a;return(a=o.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Hh),this.root.sharedNodes.clear()}}}function A2(e){e.updateLayout()}function D2(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:s}=e.layout,{animationType:i}=e.options,o=t.source!==e.layout.source;if(i==="size")Rt(f=>{const h=o?t.measuredBox[f]:t.layoutBox[f],y=Ge(h);h.min=r[f].min,h.max=h.min+y});else if(i==="x"||i==="y"){const f=i==="x"?"y":"x";Ru(o?t.measuredBox[f]:t.layoutBox[f],r[f])}else zy(i,t.layoutBox,r)&&Rt(f=>{const h=o?t.measuredBox[f]:t.layoutBox[f],y=Ge(r[f]);h.max=h.min+y,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+y)});const a=kr();Cs(a,r,t.layoutBox);const u=kr();o?Cs(u,e.applyTransform(s,!0),t.measuredBox):Cs(u,r,t.layoutBox);const c=!Ry(a);let d=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:h,layout:y}=f;if(h&&y){const x=e.options.layoutAnchor||void 0,w=Te();Vo(w,t.layoutBox,h.layoutBox,x);const b=Te();Vo(b,r,y.layoutBox,x),Iy(w,b)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=b,e.relativeTargetOrigin=w,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:u,layoutDelta:a,hasLayoutChanged:c,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function R2(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function I2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function V2(e){e.clearSnapshot()}function Hh(e){e.clearMeasurements()}function F2(e){e.isLayoutDirty=!0,e.updateLayout()}function $h(e){e.isLayoutDirty=!1}function O2(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function z2(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Uh(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function B2(e){e.resolveTargetDelta()}function H2(e){e.calcProjection()}function $2(e){e.resetSkewAndRotation()}function U2(e){e.removeLeadSnapshot()}function Wh(e,t,n){e.translate=ae(t.translate,0,n),e.scale=ae(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Gh(e,t,n,r){e.min=ae(t.min,n.min,r),e.max=ae(t.max,n.max,r)}function W2(e,t,n,r){Gh(e.x,t.x,n.x,r),Gh(e.y,t.y,n.y,r)}function G2(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const K2={duration:.45,ease:[.4,0,.1,1]},Kh=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),qh=Kh("applewebkit/")&&!Kh("chrome/")?Math.round:tt;function Yh(e){e.min=qh(e.min),e.max=qh(e.max)}function q2(e){Yh(e.x),Yh(e.y)}function zy(e,t,n){return e==="position"||e==="preserve-aspect"&&!p2(Vh(t),Vh(n),.2)}function Y2(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const X2=Oy({attachResizeListener:(e,t)=>Xs(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),tl={current:void 0},By=Oy({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!tl.current){const e=new X2({});e.mount(window),e.setOptions({layoutScroll:!0}),tl.current=e}return tl.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Qn=p.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Xh(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Z2(...e){return t=>{let n=!1;const r=e.map(s=>{const i=Xh(s,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let s=0;s{const{width:y,height:x,top:w,left:b,right:m,bottom:g,direction:v}=u.current;if(t||i===!1||!a.current||!y||!x)return;const k=v==="rtl",S=n==="left"?k?`right: ${m}`:`left: ${b}`:k?`left: ${b}`:`right: ${m}`,C=r==="bottom"?`bottom: ${g}`:`top: ${w}`;a.current.dataset.motionPopId=o;const P=document.createElement("style");c&&(P.nonce=c);const j=s??document.head;return j.appendChild(P),P.sheet&&P.sheet.insertRule(` - [data-motion-pop-id="${o}"] { - position: absolute !important; - width: ${y}px !important; - height: ${x}px !important; - ${S}px !important; - ${C}px !important; - } - `),()=>{var M;(M=a.current)==null||M.removeAttribute("data-motion-pop-id"),j.contains(P)&&j.removeChild(P)}},[t]),l.jsx(J2,{isPresent:t,childRef:a,sizeRef:u,pop:i,children:i===!1?e:p.cloneElement(e,{ref:f})})}const tj=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:s,presenceAffectsLayout:i,mode:o,anchorX:a,anchorY:u,root:c})=>{const d=en(nj),f=p.useId(),h=p.useRef(n),y=p.useRef(r);ni(()=>{h.current=n,y.current=r});let x=!0,w=p.useMemo(()=>(x=!1,{id:f,initial:t,isPresent:n,custom:s,onExitComplete:b=>{d.set(b,!0);for(const m of d.values())if(!m)return;r&&r()},register:b=>(d.set(b,!1),()=>{var m;d.delete(b),!h.current&&!d.size&&((m=y.current)==null||m.call(y))})}),[n,d,r]);return i&&x&&(w={...w}),p.useMemo(()=>{d.forEach((b,m)=>d.set(m,!1))},[n]),p.useEffect(()=>{!n&&!d.size&&r&&r()},[n]),e=l.jsx(ej,{pop:o==="popLayout",isPresent:n,anchorX:a,anchorY:u,root:c,children:e}),l.jsx(la.Provider,{value:w,children:e})};function nj(){return new Map}function Hy(e=!0){const t=p.useContext(la);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:s}=t,i=p.useId();p.useEffect(()=>{if(e)return s(i)},[e]);const o=p.useCallback(()=>e&&r&&r(i),[i,r,e]);return!n&&r?[!1,o]:[!0]}const Ei=e=>e.key||"";function Zh(e){const t=[];return p.Children.forEach(e,n=>{p.isValidElement(n)&&t.push(n)}),t}const rj=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:s=!0,mode:i="sync",propagate:o=!1,anchorX:a="left",anchorY:u="top",root:c})=>{const[d,f]=Hy(o),h=p.useMemo(()=>Zh(e),[e]),y=o&&!d?[]:h.map(Ei),x=p.useRef(!0),w=p.useRef(h),b=en(()=>new Map),m=p.useRef(new Set),[g,v]=p.useState(h),[k,S]=p.useState(h);ni(()=>{x.current=!1,w.current=h;for(let j=0;j{const M=Ei(j),T=o&&!d?!1:h===k||y.includes(M),O=()=>{if(m.current.has(M))return;if(b.has(M))m.current.add(M),b.set(M,!0);else return;let G=!0;b.forEach(W=>{W||(G=!1)}),G&&(P==null||P(),S(w.current),o&&(f==null||f()),r&&r())};return l.jsx(tj,{isPresent:T,initial:!x.current||n?void 0:!1,custom:t,presenceAffectsLayout:s,mode:i,root:c,onExitComplete:T?void 0:O,anchorX:a,anchorY:u,children:j},M)})})},$y=p.createContext({strict:!1}),Qh={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Jh=!1;function sj(){if(Jh)return;const e={};for(const t in Qh)e[t]={isEnabled:n=>Qh[t].some(r=>!!n[r])};vy(e),Jh=!0}function Uy(){return sj(),BS()}function ij(e){const t=Uy();for(const n in e)t[n]={...t[n],...e[n]};vy(t)}const oj=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Fo(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||oj.has(e)}let Wy=e=>!Fo(e);function Gy(e){typeof e=="function"&&(Wy=t=>t.startsWith("on")?!Fo(t):e(t))}try{Gy(require("@emotion/is-prop-valid").default)}catch{}function aj(e,t,n){const r={};for(const s in e)s==="values"&&typeof e.values=="object"||_e(e[s])||(Wy(s)||n===!0&&Fo(s)||!t&&!Fo(s)||e.draggable&&s.startsWith("onDrag"))&&(r[s]=e[s]);return r}function lj({children:e,isValidProp:t,...n}){t&&Gy(t);const r=p.useContext(Qn);n={...r,...n},n.transition=ld(n.transition,r.transition),n.isStatic=en(()=>n.isStatic);const s=p.useMemo(()=>n,[JSON.stringify(n.transition),n.transformPagePoint,n.reducedMotion,n.skipAnimations]);return l.jsx(Qn.Provider,{value:s,children:e})}const fa=p.createContext({});function uj(e,t){if(da(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Ys(n)?n:void 0,animate:Ys(r)?r:void 0}}return e.inherit!==!1?t:{}}function cj(e){const{initial:t,animate:n}=uj(e,p.useContext(fa));return p.useMemo(()=>({initial:t,animate:n}),[em(t),em(n)])}function em(e){return Array.isArray(e)?e.join(" "):e}const kd=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Ky(e,t,n){for(const r in t)!_e(t[r])&&!Cy(r,n)&&(e[r]=t[r])}function dj({transformTemplate:e},t){return p.useMemo(()=>{const n=kd();return vd(n,t,e),Object.assign({},n.vars,n.style)},[t])}function fj(e,t){const n=e.style||{},r={};return Ky(r,n,e),Object.assign(r,dj(e,t)),r}function hj(e,t){const n={},r=fj(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const qy=()=>({...kd(),attrs:{}});function mj(e,t,n,r){const s=p.useMemo(()=>{const i=qy();return Ty(i,t,Ny(r),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};Ky(i,e.style,e),s.style={...i,...s.style}}return s}const pj=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function bd(e){return typeof e!="string"||e.includes("-")?!1:!!(pj.indexOf(e)>-1||/[A-Z]/u.test(e))}function gj(e,t,n,{latestValues:r},s,i=!1,o){const u=(o??bd(e)?mj:hj)(t,r,s,e),c=aj(t,typeof e=="string",i),d=e!==p.Fragment?{...c,...u,ref:n}:{},{children:f}=t,h=p.useMemo(()=>_e(f)?f.get():f,[f]);return p.createElement(e,{...d,children:h})}function yj({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,s){return{latestValues:xj(n,r,s,e),renderState:t()}}function xj(e,t,n,r){const s={},i=r(e,{});for(const h in i)s[h]=Zi(i[h]);let{initial:o,animate:a}=e;const u=da(e),c=yy(e);t&&c&&!u&&e.inherit!==!1&&(o===void 0&&(o=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||o===!1;const f=d?a:o;if(f&&typeof f!="boolean"&&!ca(f)){const h=Array.isArray(f)?f:[f];for(let y=0;y(t,n)=>{const r=p.useContext(fa),s=p.useContext(la),i=()=>yj(e,t,r,s);return n?i():en(i)},vj=Yy({scrapeMotionValuesFromProps:wd,createRenderState:kd}),wj=Yy({scrapeMotionValuesFromProps:_y,createRenderState:qy}),kj=Symbol.for("motionComponentSymbol");function bj(e,t,n){const r=p.useRef(n);p.useInsertionEffect(()=>{r.current=n});const s=p.useRef(null);return p.useCallback(i=>{var a;i&&((a=e.onMount)==null||a.call(e,i)),t&&(i?t.mount(i):t.unmount());const o=r.current;if(typeof o=="function")if(i){const u=o(i);typeof u=="function"&&(s.current=u)}else s.current?(s.current(),s.current=null):o(i);else o&&(o.current=i)},[t])}const Xy=p.createContext({});function or(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Sj(e,t,n,r,s,i){var v,k;const{visualElement:o}=p.useContext(fa),a=p.useContext($y),u=p.useContext(la),c=p.useContext(Qn),d=c.reducedMotion,f=c.skipAnimations,h=p.useRef(null),y=p.useRef(!1);r=r||a.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:o,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:d,skipAnimations:f,isSVG:i}),y.current&&h.current&&(h.current.manuallyAnimateOnMount=!0));const x=h.current,w=p.useContext(Xy);x&&!x.projection&&s&&(x.type==="html"||x.type==="svg")&&jj(h.current,n,s,w);const b=p.useRef(!1);p.useInsertionEffect(()=>{x&&b.current&&x.update(n,u)});const m=n[ry],g=p.useRef(!!m&&typeof window<"u"&&!((v=window.MotionHandoffIsComplete)!=null&&v.call(window,m))&&((k=window.MotionHasOptimisedAnimation)==null?void 0:k.call(window,m)));return ni(()=>{y.current=!0,x&&(b.current=!0,window.MotionIsMounted=!0,x.updateFeatures(),x.scheduleRenderMicrotask(),g.current&&x.animationState&&x.animationState.animateChanges())}),p.useEffect(()=>{x&&(!g.current&&x.animationState&&x.animationState.animateChanges(),g.current&&(queueMicrotask(()=>{var S;(S=window.MotionHandoffMarkAsComplete)==null||S.call(window,m)}),g.current=!1),x.enteringChildren=void 0)}),x}function jj(e,t,n,r){const{layoutId:s,layout:i,drag:o,dragConstraints:a,layoutScroll:u,layoutRoot:c,layoutAnchor:d,layoutCrossfade:f}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Zy(e.parent)),e.projection.setOptions({layoutId:s,layout:i,alwaysMeasureLayout:!!o||a&&or(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:r,crossfade:f,layoutScroll:u,layoutRoot:c,layoutAnchor:d})}function Zy(e){if(e)return e.options.allowProjection!==!1?e.projection:Zy(e.parent)}function nl(e,{forwardMotionProps:t=!1,type:n}={},r,s){r&&ij(r);const i=n?n==="svg":bd(e),o=i?wj:vj;function a(c,d){let f;const h={...p.useContext(Qn),...c,layoutId:Pj(c)},{isStatic:y}=h,x=cj(c),w=o(c,y);if(!y&&typeof window<"u"){Cj();const b=Tj(h);f=b.MeasureLayout,x.visualElement=Sj(e,w,h,s,b.ProjectionNode,i)}return l.jsxs(fa.Provider,{value:x,children:[f&&x.visualElement?l.jsx(f,{visualElement:x.visualElement,...h}):null,gj(e,c,bj(w,x.visualElement,d),w,y,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const u=p.forwardRef(a);return u[kj]=e,u}function Pj({layoutId:e}){const t=p.useContext(Wc).id;return t&&e!==void 0?t+"-"+e:e}function Cj(e,t){p.useContext($y).strict}function Tj(e){const t=Uy(),{drag:n,layout:r}=t;if(!n&&!r)return{};const s={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?s.MeasureLayout:void 0,ProjectionNode:s.ProjectionNode}}function Ej(e,t){if(typeof Proxy>"u")return nl;const n=new Map,r=(i,o)=>nl(i,o,e,t),s=(i,o)=>r(i,o);return new Proxy(s,{get:(i,o)=>o==="create"?r:(n.has(o)||n.set(o,nl(o,void 0,e,t)),n.get(o))})}const Nj=(e,t)=>t.isSVG??bd(e)?new s2(t):new QS(t,{allowProjection:e!==p.Fragment});class _j extends Mn{constructor(t){super(t),t.animationState||(t.animationState=u2(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();ca(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let Mj=0;class Lj extends Mn{constructor(){super(...arguments),this.id=Mj++,this.isExitComplete=!1}update(){var i;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:o,custom:a}=this.node.getProps();if(typeof o=="string"||typeof o=="object"&&o!==null&&!Array.isArray(o)){const u=Wn(this.node,o,a);if(u){const{transition:c,transitionEnd:d,...f}=u;for(const h in f)(i=this.node.getValue(h))==null||i.jump(f[h])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const s=this.node.animationState.setActive("exit",!t);n&&!t&&s.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Aj={animation:{Feature:_j},exit:{Feature:Lj}};function oi(e){return{point:{x:e.pageX,y:e.pageY}}}const Dj=e=>t=>md(t)&&e(t,oi(t));function Ts(e,t,n,r){return Xs(e,t,Dj(n),r)}const Qy=({current:e})=>e?e.ownerDocument.defaultView:null,tm=(e,t)=>Math.abs(e-t);function Rj(e,t){const n=tm(e.x,t.x),r=tm(e.y,t.y);return Math.sqrt(n**2+r**2)}const nm=new Set(["auto","scroll"]);class Jy{constructor(t,n,{transformPagePoint:r,contextWindow:s=window,dragSnapToOrigin:i=!1,distanceThreshold:o=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=x=>{this.handleScroll(x.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Ni(this.lastRawMoveEventInfo,this.transformPagePoint));const x=rl(this.lastMoveEventInfo,this.history),w=this.startEvent!==null,b=Rj(x.offset,{x:0,y:0})>=this.distanceThreshold;if(!w&&!b)return;const{point:m}=x,{timestamp:g}=Me;this.history.push({...m,timestamp:g});const{onStart:v,onMove:k}=this.handlers;w||(v&&v(this.lastMoveEvent,x),this.startEvent=this.lastMoveEvent),k&&k(this.lastMoveEvent,x)},this.handlePointerMove=(x,w)=>{this.lastMoveEvent=x,this.lastRawMoveEventInfo=w,this.lastMoveEventInfo=Ni(w,this.transformPagePoint),Z.update(this.updatePoint,!0)},this.handlePointerUp=(x,w)=>{this.end();const{onEnd:b,onSessionEnd:m,resumeAnimation:g}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&g&&g(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=rl(x.type==="pointercancel"?this.lastMoveEventInfo:Ni(w,this.transformPagePoint),this.history);this.startEvent&&b&&b(x,v),m&&m(x,v)},!md(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=s||window;const u=oi(t),c=Ni(u,this.transformPagePoint),{point:d}=c,{timestamp:f}=Me;this.history=[{...d,timestamp:f}];const{onSessionStart:h}=n;h&&h(t,rl(c,this.history));const y={passive:!0,capture:!0};this.removeListeners=ri(Ts(this.contextWindow,"pointermove",this.handlePointerMove,y),Ts(this.contextWindow,"pointerup",this.handlePointerUp,y),Ts(this.contextWindow,"pointercancel",this.handlePointerUp,y)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(nm.has(r.overflowX)||nm.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,s=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:s.x-n.x,y:s.y-n.y};i.x===0&&i.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(t,s),Z.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),vt(this.updatePoint)}}function Ni(e,t){return t?{point:t(e.point)}:e}function rm(e,t){return{x:e.x-t.x,y:e.y-t.y}}function rl({point:e},t){return{point:e,delta:rm(e,ex(t)),offset:rm(e,Ij(t)),velocity:Vj(t,.1)}}function Ij(e){return e[0]}function ex(e){return e[e.length-1]}function Vj(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const s=ex(e);for(;n>=0&&(r=e[n],!(s.timestamp-r.timestamp>at(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&s.timestamp-r.timestamp>at(t)*2&&(r=e[1]);const i=pt(s.timestamp-r.timestamp);if(i===0)return{x:0,y:0};const o={x:(s.x-r.x)/i,y:(s.y-r.y)/i};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function Fj(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?ae(n,e,r.max):Math.min(e,n)),e}function sm(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Oj(e,{top:t,left:n,bottom:r,right:s}){return{x:sm(e.x,n,s),y:sm(e.y,t,r)}}function im(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=Vr(t.min,t.max-r,e.min):r>s&&(n=Vr(e.min,e.max-s,t.min)),Mt(0,1,n)}function Hj(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Iu=.35;function $j(e=Iu){return e===!1?e=0:e===!0&&(e=Iu),{x:om(e,"left","right"),y:om(e,"top","bottom")}}function om(e,t,n){return{min:am(e,t),max:am(e,n)}}function am(e,t){return typeof e=="number"?e:e[t]||0}const Uj=new WeakMap;class Wj{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Te(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:s}=this.visualElement;if(s&&s.isPresent===!1)return;const i=f=>{n&&this.snapToCursor(oi(f).point),this.stopAnimation()},o=(f,h)=>{const{drag:y,dragPropagation:x,onDragStart:w}=this.getProps();if(y&&!x&&(this.openDragLock&&this.openDragLock(),this.openDragLock=gS(y),!this.openDragLock))return;this.latestPointerEvent=f,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Rt(m=>{let g=this.getAxisMotionValue(m).get()||0;if(zt.test(g)){const{projection:v}=this.visualElement;if(v&&v.layout){const k=v.layout.layoutBox[m];k&&(g=Ge(k)*(parseFloat(g)/100))}}this.originPoint[m]=g}),w&&Z.update(()=>w(f,h),!1,!0),Cu(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(f,h)=>{this.latestPointerEvent=f,this.latestPanInfo=h;const{dragPropagation:y,dragDirectionLock:x,onDirectionLock:w,onDrag:b}=this.getProps();if(!y&&!this.openDragLock)return;const{offset:m}=h;if(x&&this.currentDirection===null){this.currentDirection=Kj(m),this.currentDirection!==null&&w&&w(this.currentDirection);return}this.updateAxis("x",h.point,m),this.updateAxis("y",h.point,m),this.visualElement.render(),b&&Z.update(()=>b(f,h),!1,!0)},u=(f,h)=>{this.latestPointerEvent=f,this.latestPanInfo=h,this.stop(f,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>{const{dragSnapToOrigin:f}=this.getProps();(f||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:d}=this.getProps();this.panSession=new Jy(t,{onSessionStart:i,onStart:o,onMove:a,onSessionEnd:u,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:r,contextWindow:Qy(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,s=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!s||!r)return;const{velocity:o}=s;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&Z.postRender(()=>a(r,s))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:s}=this.getProps();if(!r||!_i(t,s,this.currentDirection))return;const i=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=Fj(o,this.constraints[t],this.elastic[t])),i.set(o)}resolveConstraints(){var i;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(i=this.visualElement.projection)==null?void 0:i.layout,s=this.constraints;t&&or(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=Oj(r.layoutBox,t):this.constraints=!1,this.elastic=$j(n),s!==this.constraints&&!or(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Rt(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=Hj(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!or(t))return!1;const r=t.current,{projection:s}=this.visualElement;if(!s||!s.layout)return!1;s.root&&(s.root.scroll=void 0,s.root.updateScroll());const i=GS(r,s.root,this.visualElement.getTransformPagePoint());let o=zj(s.layout.layoutBox,i);if(n){const a=n($S(o));this.hasMutatedConstraints=!!a,a&&(o=ky(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:s,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),u=this.constraints||{},c=Rt(d=>{if(!_i(d,n,this.currentDirection))return;let f=u&&u[d]||{};(o===!0||o===d)&&(f={min:0,max:0});const h=s?200:1e6,y=s?40:1e7,x={type:"inertia",velocity:r?t[d]:0,bounceStiffness:h,bounceDamping:y,timeConstant:750,restDelta:1,restSpeed:10,...i,...f};return this.startAxisValueAnimation(d,x)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Cu(this.visualElement,t),r.start(cd(t,r,0,n,this.visualElement,!1))}stopAnimation(){Rt(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,s=this.visualElement.getProps()[n];return s||this.visualElement.getValue(t,this.visualElement.latestValues[t]??0)}snapToCursor(t){Rt(n=>{const{drag:r}=this.getProps();if(!_i(n,r,this.currentDirection))return;const{projection:s}=this.visualElement,i=this.getAxisMotionValue(n);if(s&&s.layout){const{min:o,max:a}=s.layout.layoutBox[n],u=i.get()||0;i.set(t[n]-ae(o,a,.5)+u)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!or(n)||!r||!this.constraints)return;this.stopAnimation();const s={x:0,y:0};Rt(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const u=a.get();s[o]=Bj({min:u,max:u},this.constraints[o])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),Rt(o=>{if(!_i(o,t,null))return;const a=this.getAxisMotionValue(o),{min:u,max:c}=this.constraints[o];a.set(ae(u,c,s[o]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;Uj.set(this.visualElement,this);const t=this.visualElement.current,n=Ts(t,"pointerdown",c=>{const{drag:d,dragListener:f=!0}=this.getProps(),h=c.target,y=h!==t&&bS(h);d&&f&&!y&&this.start(c)});let r;const s=()=>{const{dragConstraints:c}=this.getProps();or(c)&&c.current&&(this.constraints=this.resolveRefConstraints(),r||(r=Gj(t,c.current,()=>this.scalePositionWithinConstraints())))},{projection:i}=this.visualElement,o=i.addEventListener("measure",s);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),Z.read(s);const a=Xs(window,"resize",()=>this.scalePositionWithinConstraints()),u=i.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d})=>{this.isDragging&&d&&(Rt(f=>{const h=this.getAxisMotionValue(f);h&&(this.originPoint[f]+=c[f].translate,h.set(h.get()+c[f].translate))}),this.visualElement.render())});return()=>{a(),n(),o(),u&&u(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:s=!1,dragConstraints:i=!1,dragElastic:o=Iu,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:s,dragConstraints:i,dragElastic:o,dragMomentum:a}}}function lm(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function Gj(e,t,n){const r=Mu(e,lm(n)),s=Mu(t,lm(n));return()=>{r(),s()}}function _i(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function Kj(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class qj extends Mn{constructor(t){super(t),this.removeGroupControls=tt,this.removeListeners=tt,this.controls=new Wj(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||tt}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const sl=e=>(t,n)=>{e&&Z.update(()=>e(t,n),!1,!0)};class Yj extends Mn{constructor(){super(...arguments),this.removePointerDownListener=tt}onPointerDown(t){this.session=new Jy(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Qy(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:s}=this.node.getProps();return{onSessionStart:sl(t),onStart:sl(n),onMove:sl(r),onEnd:(i,o)=>{delete this.session,s&&Z.postRender(()=>s(i,o))}}}mount(){this.removePointerDownListener=Ts(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let il=!1;class Xj extends p.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:s}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),r&&r.register&&s&&r.register(i),il&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),Qi.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:s,isPresent:i}=this.props,{projection:o}=r;return o&&(o.isPresent=i,t.layoutDependency!==n&&o.setOptions({...o.options,layoutDependency:n}),il=!0,s||t.layoutDependency!==n||n===void 0||t.isPresent!==i?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||Z.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),Or.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:s}=t;il=!0,s&&(s.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(s),r&&r.deregister&&r.deregister(s))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function tx(e){const[t,n]=Hy(),r=p.useContext(Wc);return l.jsx(Xj,{...e,layoutGroup:r,switchLayoutGroup:p.useContext(Xy),isPresent:t,safeToRemove:n})}const Zj={pan:{Feature:Yj},drag:{Feature:qj,ProjectionNode:By,MeasureLayout:tx}};function um(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const s="onHover"+n,i=r[s];i&&Z.postRender(()=>i(t,oi(t)))}class Qj extends Mn{mount(){const{current:t}=this.node;t&&(this.unmount=xS(t,(n,r)=>(um(this.node,r,"Start"),s=>um(this.node,s,"End"))))}unmount(){}}class Jj extends Mn{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=ri(Xs(this.node.current,"focus",()=>this.onFocus()),Xs(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function cm(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const s="onTap"+(n==="End"?"":n),i=r[s];i&&Z.postRender(()=>i(t,oi(t)))}class eP extends Mn{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=jS(t,(s,i)=>(cm(this.node,i,"Start"),(o,{success:a})=>cm(this.node,o,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const Vu=new WeakMap,ol=new WeakMap,tP=e=>{const t=Vu.get(e.target);t&&t(e)},nP=e=>{e.forEach(tP)};function rP({root:e,...t}){const n=e||document;ol.has(n)||ol.set(n,{});const r=ol.get(n),s=JSON.stringify(t);return r[s]||(r[s]=new IntersectionObserver(nP,{root:e,...t})),r[s]}function sP(e,t,n){const r=rP(t);return Vu.set(e,n),r.observe(e),()=>{Vu.delete(e),r.unobserve(e)}}const iP={some:0,all:1};class oP extends Mn{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var u;(u=this.stopObserver)==null||u.call(this);const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:s="some",once:i}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof s=="number"?s:iP[s]},a=c=>{const{isIntersecting:d}=c;if(this.isInView===d||(this.isInView=d,i&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:f,onViewportLeave:h}=this.node.getProps(),y=d?f:h;y&&y(c)};this.stopObserver=sP(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(aP(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function aP({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const lP={inView:{Feature:oP},tap:{Feature:eP},focus:{Feature:Jj},hover:{Feature:Qj}},uP={layout:{ProjectionNode:By,MeasureLayout:tx}},cP={...Aj,...lP,...Zj,...uP},Kt=Ej(cP,Nj);function Oo(e){return typeof window>"u"?!1:e?K0():ad()}const dP=50,dm=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),fP=()=>({time:0,x:dm(),y:dm()}),hP={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function fm(e,t,n,r){const s=n[t],{length:i,position:o}=hP[t],a=s.current,u=n.time;s.current=Math.abs(e[`scroll${o}`]),s.scrollLength=e[`scroll${i}`]-e[`client${i}`],s.offset.length=0,s.offset[0]=0,s.offset[1]=s.scrollLength,s.progress=Vr(0,s.scrollLength,s.current);const c=r-u;s.velocity=c>dP?0:Yc(s.current-a,c)}function mP(e,t,n){fm(e,"x",t,n),fm(e,"y",t,n),t.time=n}function pP(e,t){const n={x:0,y:0};let r=e;for(;r&&r!==t;)if(Ps(r))n.x+=r.offsetLeft,n.y+=r.offsetTop,r=r.offsetParent;else if(r.tagName==="svg"){const s=r.getBoundingClientRect();r=r.parentElement;const i=r.getBoundingClientRect();n.x+=s.left-i.left,n.y+=s.top-i.top}else if(r instanceof SVGGraphicsElement){const{x:s,y:i}=r.getBBox();n.x+=s,n.y+=i;let o=null,a=r.parentNode;for(;!o;)a.tagName==="svg"&&(o=a),a=r.parentNode;r=o}else break;return n}const Fu={start:0,center:.5,end:1};function hm(e,t,n=0){let r=0;if(e in Fu&&(e=Fu[e]),typeof e=="string"){const s=parseFloat(e);e.endsWith("px")?r=s:e.endsWith("%")?e=s/100:e.endsWith("vw")?r=s/100*document.documentElement.clientWidth:e.endsWith("vh")?r=s/100*document.documentElement.clientHeight:e=s}return typeof e=="number"&&(r=t*e),n+r}const gP=[0,0];function yP(e,t,n,r){let s=Array.isArray(e)?e:gP,i=0,o=0;return typeof e=="number"?s=[e,e]:typeof e=="string"&&(e=e.trim(),e.includes(" ")?s=e.split(" "):s=[e,Fu[e]?e:"0"]),i=hm(s[0],n,r),o=hm(s[1],t),i-o}const fs={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]},xP={x:0,y:0};function vP(e){return"getBBox"in e&&e.tagName!=="svg"?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function wP(e,t,n){const{offset:r=fs.All}=n,{target:s=e,axis:i="y"}=n,o=i==="y"?"height":"width",a=s!==e?pP(s,e):xP,u=s===e?{width:e.scrollWidth,height:e.scrollHeight}:vP(s),c={width:e.clientWidth,height:e.clientHeight};t[i].offset.length=0;let d=!t[i].interpolate;const f=r.length;for(let h=0;h{kP(e,r.target,n),mP(e,n,s),(r.offset||r.target)&&wP(e,n,r)},notify:()=>t(n)}}const ir=new WeakMap,mm=new WeakMap,al=new WeakMap,pm=new WeakMap,Mi=new WeakMap,gm=e=>e===document.scrollingElement?window:e;function nx(e,{container:t=document.scrollingElement,trackContentSize:n=!1,...r}={}){if(!t)return tt;let s=al.get(t);s||(s=new Set,al.set(t,s));const i=fP(),o=bP(t,e,i,r);if(s.add(o),!ir.has(t)){const u=()=>{for(const h of s)h.measure(Me.timestamp);Z.preUpdate(c)},c=()=>{for(const h of s)h.notify()},d=()=>Z.read(u);ir.set(t,d);const f=gm(t);window.addEventListener("resize",d),t!==document.documentElement&&mm.set(t,Mu(t,d)),f.addEventListener("scroll",d),d()}if(n&&!Mi.has(t)){const u=ir.get(t),c={width:t.scrollWidth,height:t.scrollHeight};pm.set(t,c);const d=()=>{const h=t.scrollWidth,y=t.scrollHeight;(c.width!==h||c.height!==y)&&(u(),c.width=h,c.height=y)},f=Z.read(d,!0);Mi.set(t,f)}const a=ir.get(t);return Z.read(a,!1,!0),()=>{var f;vt(a);const u=al.get(t);if(!u||(u.delete(o),u.size))return;const c=ir.get(t);ir.delete(t),c&&(gm(t).removeEventListener("scroll",c),(f=mm.get(t))==null||f(),window.removeEventListener("resize",c));const d=Mi.get(t);d&&(vt(d),Mi.delete(t)),pm.delete(t)}}const SP=[[fs.Enter,"entry"],[fs.Exit,"exit"],[fs.Any,"cover"],[fs.All,"contain"]],ym={start:0,end:1};function jP(e){const t=e.trim().split(/\s+/);if(t.length!==2)return;const n=ym[t[0]],r=ym[t[1]];if(!(n===void 0||r===void 0))return[n,r]}function PP(e){if(e.length!==2)return;const t=[];for(const n of e)if(Array.isArray(n))t.push(n);else if(typeof n=="string"){const r=jP(n);if(!r)return;t.push(r)}else return;return t}function CP(e,t){const n=PP(e);if(!n)return!1;for(let r=0;r<2;r++){const s=n[r],i=t[r];if(s[0]!==i[0]||s[1]!==i[1])return!1}return!0}function Sd(e){if(!e)return{rangeStart:"contain 0%",rangeEnd:"contain 100%"};for(const[t,n]of SP)if(CP(e,t))return{rangeStart:`${n} 0%`,rangeEnd:`${n} 100%`}}const xm=new Map;function vm(e){const t={value:0},n=nx(r=>{t.value=r[e.axis].progress*100},e);return{currentTime:t,cancel:n}}function rx({source:e,container:t,...n}){const{axis:r}=n;e&&(t=e);let s=xm.get(t);s||(s=new Map,xm.set(t,s));const i=n.target??"self";let o=s.get(i);o||(o={},s.set(i,o));const a=r+(n.offset??[]).join(",");return o[a]||(n.target&&Oo(n.target)?Sd(n.offset)?o[a]=new ViewTimeline({subject:n.target,axis:r}):o[a]=vm({container:t,...n}):Oo()?o[a]=new ScrollTimeline({source:t,axis:r}):o[a]=vm({container:t,...n})),o[a]}function TP(e,t){const n=rx(t),r=t.target?Sd(t.offset):void 0,s=t.target?Oo(t.target)&&!!r:Oo();return e.attachTimeline({timeline:s?n:void 0,...r&&s&&{rangeStart:r.rangeStart,rangeEnd:r.rangeEnd},observe:i=>(i.pause(),gy(o=>{i.time=i.iterationDuration*o},n))})}function EP(e){return e&&(e.target||e.offset)}function NP(e){return e.length===2}function _P(e,t){return NP(e)||EP(t)?nx(n=>{e(n[t.axis].progress,n)},t):gy(e,rx(t))}function sx(e,{axis:t="y",container:n=document.scrollingElement,...r}={}){if(!n)return tt;const s={axis:t,container:n,...r};return typeof e=="function"?_P(e,s):TP(e,s)}const MP=()=>({scrollX:Ct(0),scrollY:Ct(0),scrollXProgress:Ct(0),scrollYProgress:Ct(0)}),br=e=>e?!e.current:!1;function wm(e,t,n,r){return{factory:s=>{let i;const o=()=>{if(br(n)||br(r)){Or.read(o);return}i=sx(s,{...t,axis:e,container:(n==null?void 0:n.current)||void 0,target:(r==null?void 0:r.current)||void 0})};return Or.read(o),()=>{dy(o),i==null||i()}},times:[0,1],keyframes:[0,1],ease:s=>s,duration:1}}function LP(e,t){return typeof window>"u"?!1:e?K0()&&!!Sd(t):ad()}function ix({container:e,target:t,...n}={}){const r=en(MP);LP(t,n.offset)&&(r.scrollXProgress.accelerate=wm("x",n,e,t),r.scrollYProgress.accelerate=wm("y",n,e,t));const s=p.useRef(null),i=p.useRef(!1),o=p.useCallback(()=>(s.current=sx((a,{x:u,y:c})=>{r.scrollX.set(u.current),r.scrollXProgress.set(u.progress),r.scrollY.set(c.current),r.scrollYProgress.set(c.progress)},{...n,container:(e==null?void 0:e.current)||void 0,target:(t==null?void 0:t.current)||void 0}),()=>{var a;(a=s.current)==null||a.call(s)}),[e,t,JSON.stringify(n.offset)]);return ni(()=>{if(i.current=!1,br(e)||br(t)){i.current=!0;return}else return o()},[o]),p.useEffect(()=>{if(!i.current)return;let a;const u=()=>{const c=br(e),d=br(t);!c&&!d&&(a=o())};return Or.read(u),()=>{dy(u),a==null||a()}},[o]),r}function ox(e){const t=en(()=>Ct(e)),{isStatic:n}=p.useContext(Qn);if(n){const[,r]=p.useState(e);p.useEffect(()=>t.on("change",r),[])}return t}function ax(e,t){const n=ox(t()),r=()=>n.set(t());return r(),ni(()=>{const s=()=>Z.preRender(r,!1,!0),i=e.map(o=>o.on("change",s));return()=>{i.forEach(o=>o()),vt(r)}}),n}function AP(e){js.current=[],e();const t=ax(js.current,e);return js.current=void 0,t}function ln(e,t,n,r){if(typeof e=="function")return AP(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!="function")return DP(e,t,n,r);const o=typeof t=="function"?t:DS(t,n,r),a=Array.isArray(e)?km(e,o):km([e],([c])=>o(c)),u=Array.isArray(e)?void 0:e.accelerate;return u&&!u.isTransformed&&typeof t!="function"&&Array.isArray(n)&&(r==null?void 0:r.clamp)!==!1&&(a.accelerate={...u,times:t,keyframes:n,isTransformed:!0}),a}function km(e,t){const n=en(()=>[]);return ax(e,()=>{n.length=0;const r=e.length;for(let s=0;sObject.keys(n)),i=en(()=>({}));for(const o of s)i[o]=ln(e,t,n[o],r);return i}function RP(e,t={}){const{isStatic:n}=p.useContext(Qn),r=()=>_e(e)?e.get():e;if(n)return ln(r);const s=ox(r());return p.useInsertionEffect(()=>RS(s,e,t),[s,JSON.stringify(t)]),s}function IP(e,t={}){return RP(e,{type:"spring",...t})}function VP(){!xd.current&&xy();const[e]=p.useState(Do.current);return e}function FP(){const{pathname:e}=nt();return p.useEffect(()=>{window.scrollTo({top:0,left:0,behavior:"instant"})},[e]),null}const OP='a, button, [role="button"], label, select, summary, [data-cursor="hover"], .cursor-pointer',zP='input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="submit"]):not([type="button"]):not([type="file"]), textarea, [contenteditable="true"]';function BP(){const e=p.useRef(null),t=p.useRef(null),n=p.useRef(null),r=p.useRef(null),s=p.useRef(null);return p.useEffect(()=>{const i=window.matchMedia("(pointer: fine)"),o=window.matchMedia("(prefers-reduced-motion: reduce)");if(!i.matches||o.matches)return;const a=e.current,u=t.current,c=n.current,d=r.current,f=s.current;if(!a||!u||!c||!d||!f)return;document.documentElement.classList.add("hifi-cursor-on");const h=-24*Math.PI/180,y=Math.cos(h),x=Math.sin(h);let w=-100,b=-100,m=0,g=2.4,v=2.4,k=16,S=6.5,C=16,P=6.5,j=!1,M,T=performance.now();const O=N=>{const L=Math.min((N-T)/1e3,.05);T=N,g+=(v-g)*Math.min(1,L*8),k+=(C-k)*Math.min(1,L*10),S+=(P-S)*Math.min(1,L*10),m+=g*L,u.style.transform=`translate3d(${w}px, ${b}px, 0)`,c.style.transform=`translate3d(${w}px, ${b}px, 0)`;const F=Math.cos(m)*k,E=Math.sin(m)*S;d.style.transform=`translate(${F*y-E*x}px, ${F*x+E*y}px)`,M=requestAnimationFrame(O)},G=N=>{a.dataset.state=N;const L=N==="hover";v=L?7:2.4,C=L?23:16,P=L?9.5:6.5},W=N=>{w=N.clientX,b=N.clientY,j||(j=!0,a.dataset.hidden="false")},H=N=>{const L=N.target;L instanceof Element&&(L.closest(zP)?G("text"):L.closest(OP)?G("hover"):G("default"))},Y=()=>{a.dataset.down="true",f.style.left=`${w}px`,f.style.top=`${b}px`,f.classList.remove("is-live"),f.offsetWidth,f.classList.add("is-live")},q=()=>{a.dataset.down="false"},le=()=>{j=!1,a.dataset.hidden="true"};return document.addEventListener("mousemove",W,{passive:!0}),document.addEventListener("mouseover",H,{passive:!0}),document.addEventListener("mousedown",Y,{passive:!0}),document.addEventListener("mouseup",q,{passive:!0}),document.documentElement.addEventListener("mouseleave",le),window.addEventListener("blur",le),M=requestAnimationFrame(O),()=>{cancelAnimationFrame(M),document.removeEventListener("mousemove",W),document.removeEventListener("mouseover",H),document.removeEventListener("mousedown",Y),document.removeEventListener("mouseup",q),document.documentElement.removeEventListener("mouseleave",le),window.removeEventListener("blur",le),document.documentElement.classList.remove("hifi-cursor-on")}},[]),l.jsxs("div",{ref:e,className:"hifi-cursor","data-state":"default","data-hidden":"true","data-down":"false","aria-hidden":"true",children:[l.jsxs("div",{ref:n,className:"hifi-cursor__orbit",children:[l.jsx("div",{className:"hifi-cursor__ring"}),l.jsx("div",{ref:r,className:"hifi-cursor__sat"})]}),l.jsx("div",{ref:t,className:"hifi-cursor__core"}),l.jsx("div",{ref:s,className:"hifi-cursor__pulse"})]})}const HP=`${"/".replace(/\/$/,"")}/api`;let Ou=0;const zu=new Set,bm=e=>{Ou+=e,zu.forEach(t=>t(Ou))},$P=()=>Ou,UP=e=>(zu.add(e),()=>zu.delete(e)),Bu=new Set,WP=e=>(Bu.add(e),()=>Bu.delete(e));async function is(e,t={}){bm(1);try{return await GP(e,t)}finally{bm(-1)}}async function GP(e,t){const n=await fetch(`${HP}${e}`,{credentials:"include",headers:t.body instanceof FormData?{}:{"Content-Type":"application/json"},...t}),r=await n.text();let s=null;if(r)try{s=JSON.parse(r)}catch{}if(!n.ok){const i=new Error((s==null?void 0:s.error)||`Fehler ${n.status}`);throw i.status=n.status,i.code=(s==null?void 0:s.code)||null,n.status===401&&!e.startsWith("/auth/")&&Bu.forEach(o=>o()),i}if(s===null&&r){const i=new Error("Unerwartete Server-Antwort (kein gültiges JSON)");throw i.status=n.status,i.code="invalid_response",i}return s}const ce={get:(e,t)=>is(e,t),post:(e,t)=>is(e,{method:"POST",body:t instanceof FormData?t:JSON.stringify(t)}),put:(e,t)=>is(e,{method:"PUT",body:JSON.stringify(t)}),patch:(e,t)=>is(e,{method:"PATCH",body:JSON.stringify(t)}),delete:e=>is(e,{method:"DELETE"})};function KP({children:e}){const[t,n]=p.useState({pathname:null,needsSetup:null}),r=nt(),s=t.needsSetup===!1;p.useEffect(()=>{if(s)return;let o=!1;return ce.get("/setup/status").then(a=>{o||n({pathname:r.pathname,needsSetup:a.needs_setup})}).catch(()=>{o||n({pathname:r.pathname,needsSetup:!1})}),()=>{o=!0}},[r.pathname,s]);const i=t.pathname===r.pathname;return r.pathname==="/setup"?s?l.jsx(Zn,{to:"/",replace:!0}):!i||t.needsSetup===null?l.jsx("div",{className:"min-h-screen bg-white dark:bg-neutral-950"}):e:i&&t.needsSetup?l.jsx(Zn,{to:"/setup",replace:!0}):e}/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const lx=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const qP=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const YP=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase());/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const Sm=e=>{const t=YP(e);return t.charAt(0).toUpperCase()+t.slice(1)};/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */var ll={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const XP=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0;return!1},ux=p.createContext({});function _N({children:e,size:t,color:n,strokeWidth:r,absoluteStrokeWidth:s,className:i}){const o=p.useMemo(()=>({size:t,color:n,strokeWidth:r,absoluteStrokeWidth:s,className:i}),[t,n,r,s,i]);return p.createElement(ux.Provider,{value:o},e)}const ZP=()=>p.useContext(ux),QP=p.forwardRef(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:r,className:s="",children:i,iconNode:o,...a},u)=>{const{size:c=24,strokeWidth:d=2,absoluteStrokeWidth:f=!1,color:h="currentColor",className:y=""}=ZP()??{},x=r??f?Number(n??d)*24/Number(t??c):n??d;return p.createElement("svg",{ref:u,...ll,width:t??c??ll.width,height:t??c??ll.height,stroke:e??h,strokeWidth:x,className:lx("lucide",y,s),...!i&&!XP(a)&&{"aria-hidden":"true"},...a},[...o.map(([w,b])=>p.createElement(w,b)),...Array.isArray(i)?i:[i]])});/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const ee=(e,t)=>{const n=p.forwardRef(({className:r,...s},i)=>p.createElement(QP,{ref:i,iconNode:t,className:lx(`lucide-${qP(Sm(e))}`,`lucide-${e}`,r),...s}));return n.displayName=Sm(e),n};/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const JP=[["path",{d:"M2.97 12.92A2 2 0 0 0 2 14.63v3.24a2 2 0 0 0 .97 1.71l3 1.8a2 2 0 0 0 2.06 0L12 19v-5.5l-5-3-4.03 2.42Z",key:"lc1i9w"}],["path",{d:"m7 16.5-4.74-2.85",key:"1o9zyk"}],["path",{d:"m7 16.5 5-3",key:"va8pkn"}],["path",{d:"M7 16.5v5.17",key:"jnp8gn"}],["path",{d:"M12 13.5V19l3.97 2.38a2 2 0 0 0 2.06 0l3-1.8a2 2 0 0 0 .97-1.71v-3.24a2 2 0 0 0-.97-1.71L17 10.5l-5 3Z",key:"8zsnat"}],["path",{d:"m17 16.5-5-3",key:"8arw3v"}],["path",{d:"m17 16.5 4.74-2.85",key:"8rfmw"}],["path",{d:"M17 16.5v5.17",key:"k6z78m"}],["path",{d:"M7.97 4.42A2 2 0 0 0 7 6.13v4.37l5 3 5-3V6.13a2 2 0 0 0-.97-1.71l-3-1.8a2 2 0 0 0-2.06 0l-3 1.8Z",key:"1xygjf"}],["path",{d:"M12 8 7.26 5.15",key:"1vbdud"}],["path",{d:"m12 8 4.74-2.85",key:"3rx089"}],["path",{d:"M12 13.5V8",key:"1io7kd"}]],eC=ee("boxes",JP);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const tC=[["path",{d:"m21 8-2 2-1.5-3.7A2 2 0 0 0 15.646 5H8.4a2 2 0 0 0-1.903 1.257L5 10 3 8",key:"1imjwt"}],["path",{d:"M7 14h.01",key:"1qa3f1"}],["path",{d:"M17 14h.01",key:"7oqj8z"}],["rect",{width:"18",height:"8",x:"3",y:"10",rx:"2",key:"a7itu8"}],["path",{d:"M5 18v2",key:"ppbyun"}],["path",{d:"M19 18v2",key:"gy7782"}]],nC=ee("car-front",tC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const rC=[["path",{d:"M19 17h2c.6 0 1-.4 1-1v-3c0-.9-.7-1.7-1.5-1.9C18.7 10.6 16 10 16 10s-1.3-1.4-2.2-2.3c-.5-.4-1.1-.7-1.8-.7H5c-.6 0-1.1.4-1.4.9l-1.4 2.9A3.7 3.7 0 0 0 2 12v4c0 .6.4 1 1 1h2",key:"5owen"}],["circle",{cx:"7",cy:"17",r:"2",key:"u2ysq9"}],["path",{d:"M9 17h6",key:"r8uit2"}],["circle",{cx:"17",cy:"17",r:"2",key:"axvx0g"}]],zo=ee("car",rC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const sC=[["path",{d:"M18 19V9a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v8a2 2 0 0 0 2 2h2",key:"19jm3t"}],["path",{d:"M2 9h3a1 1 0 0 1 1 1v2a1 1 0 0 1-1 1H2",key:"13hakp"}],["path",{d:"M22 17v1a1 1 0 0 1-1 1H10v-9a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1v9",key:"1crci8"}],["circle",{cx:"8",cy:"19",r:"2",key:"t8fc5s"}]],iC=ee("caravan",sC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const oC=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],aC=ee("check",oC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const lC=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],uC=ee("chevron-down",lC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const cC=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],dC=ee("chevron-left",cC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const fC=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],hC=ee("chevron-right",fC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const mC=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],pC=ee("chevron-up",mC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const gC=[["path",{d:"M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z",key:"kmsa83"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],yC=ee("circle-play",gC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const xC=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]],cx=ee("clock",xC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const vC=[["path",{d:"M11 10.27 7 3.34",key:"16pf9h"}],["path",{d:"m11 13.73-4 6.93",key:"794ttg"}],["path",{d:"M12 22v-2",key:"1osdcq"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M14 12h8",key:"4f43i9"}],["path",{d:"m17 20.66-1-1.73",key:"eq3orb"}],["path",{d:"m17 3.34-1 1.73",key:"2wel8s"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"m20.66 17-1.73-1",key:"sg0v6f"}],["path",{d:"m20.66 7-1.73 1",key:"1ow05n"}],["path",{d:"m3.34 17 1.73-1",key:"nuk764"}],["path",{d:"m3.34 7 1.73 1",key:"1ulond"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["circle",{cx:"12",cy:"12",r:"8",key:"46899m"}]],wC=ee("cog",vC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const kC=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],bC=ee("external-link",kC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const SC=[["path",{d:"M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4",key:"1slcih"}]],jC=ee("flame",SC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const PC=[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]],CC=ee("layout-dashboard",PC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const TC=[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]],EC=ee("lightbulb",TC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const NC=[["path",{d:"m10 17 5-5-5-5",key:"1bsop3"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}]],_C=ee("log-in",NC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const MC=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],Hu=ee("mail",MC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const LC=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],dx=ee("map-pin",LC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const AC=[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]],fx=ee("message-circle",AC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const DC=[["rect",{x:"5",y:"2",width:"14",height:"20",rx:"7",key:"11ol66"}],["path",{d:"M12 6v4",key:"16clxf"}]],RC=ee("mouse",DC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const IC=[["polygon",{points:"3 11 22 2 13 21 11 13 3 11",key:"1ltx0t"}]],VC=ee("navigation",IC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const FC=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]],OC=ee("package",FC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const zC=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],Jn=ee("phone",zC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const BC=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],HC=ee("send",BC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const $C=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]],UC=ee("shield-alert",$C);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const WC=[["path",{d:"M16 10a4 4 0 0 1-8 0",key:"1ltviw"}],["path",{d:"M3.103 6.034h17.794",key:"awc11p"}],["path",{d:"M3.4 5.467a2 2 0 0 0-.4 1.2V20a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6.667a2 2 0 0 0-.4-1.2l-2-2.667A2 2 0 0 0 17 2H7a2 2 0 0 0-1.6.8z",key:"o988cm"}]],GC=ee("shopping-bag",WC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const KC=[["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z",key:"emmmcr"}],["path",{d:"M7 10v12",key:"1qc93n"}]],qC=ee("thumbs-up",KC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const YC=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],XC=ee("user",YC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const ZC=[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]],QC=ee("video",ZC);/** - * @license lucide-react v1.23.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const JC=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],eT=ee("zap",JC),hx=p.createContext(null);function tT(){const e=new Date,t=e.getHours()+e.getMinutes()/60;return t>=6.5&&t<21?"light":"dark"}function nT({children:e}){const[t,n]=p.useState(()=>{const s=localStorage.getItem("hifi-theme");return s==="light"||s==="dark"?s:tT()});p.useEffect(()=>{document.documentElement.classList.toggle("dark",t==="dark"),localStorage.setItem("hifi-theme",t)},[t]);const r=()=>n(s=>s==="dark"?"light":"dark");return l.jsx(hx.Provider,{value:{theme:t,toggleTheme:r},children:e})}function rT(){return p.useContext(hx)}const sT={nav:{mainNav:"Hauptnavigation",menu:"Menü",call:"Anrufen",openMenu:"Menü öffnen",closeMenu:"Menü schließen",close:"Schließen",adminPanel:"Zum Admin-Panel",vehicles:"Fahrzeuge",services:"Leistungen",gallery:"Galerie",contact:"Kontakt",whatsapp:"WhatsApp",shop:"Zum Shop",downloads:"Downloads"},themeToggle:{label:"Theme umschalten"},languageToggle:{label:"Sprache auswählen"},footer:{routePlan:"Route planen",contactHeading:"Kontakt",contactForm:"Kontaktformular",hoursHeading:"Öffnungszeiten",open:"Geöffnet",closed:"Geschlossen",days:{monFri:"Montag – Freitag",sat:"Samstag",sun:"Sonntag"},copyright:e=>`© ${e} HifiPlanet. Alle Angaben ohne Gewähr.`,imprint:"Impressum",privacy:"Datenschutz",terms:"AGB",downloads:"Downloads",cookieSettings:"Cookie-Einstellungen"},cookieConsent:{bannerText:"Wir verwenden nur technisch notwendige Cookies. Für Google Maps, YouTube-Videos und Statistik-Cookies benötigen wir zusätzlich deine Zustimmung, da dabei Daten an Google übertragen werden.",moreInfo:"Mehr dazu in unserer",privacyPolicy:"Datenschutzerklärung",settings:"Einstellungen",onlyNecessary:"Nur notwendige",acceptAll:"Alle akzeptieren",modalTitle:"Cookie-Einstellungen",modalIntro:"Lege fest, welche Kategorien du zulassen möchtest. Mehr dazu in unserer",necessaryTitle:"Notwendig",necessaryDesc:"Für den Betrieb der Website erforderlich (z. B. Login-Session, Theme- und Cookie-Einstellung). Kann nicht deaktiviert werden.",externalTitle:"Externe Medien",externalDesc:"Google Maps und YouTube-Videos. Beim Laden werden Daten (u. a. deine IP-Adresse) an Google übertragen.",analyticsTitle:"Statistik",analyticsDesc:"Google Analytics hilft uns zu verstehen, wie die Website genutzt wird. Dabei werden Daten an Google übertragen.",cancel:"Abbrechen",saveSelection:"Auswahl speichern"},maintenance:{title:"Wartungsarbeiten",defaultMessage:"Dieser Bereich wird gerade aktualisiert. Bitte schau in Kürze wieder vorbei.",login:"Anmelden"},lightbox:{close:"Schließen",previous:"Vorheriges Bild",next:"Nächstes Bild"},home:{metaTitle:"Car-Hifi Umbauten nach Maß",metaDescription:"HifiPlanet – dein Car-Hifi Spezialist in Amorbach. Marke und Modell wählen, passende Sound-Pakete entdecken und unverbindlich anfragen.",stickyCta:"Bereit für deinen Sound-Umbau?",selectVehicle:"Fahrzeug auswählen",getInTouch:"Kontakt aufnehmen",welcome:"Willkommen bei HifiPlanet",heroTitle:"Home of pure Sound",heroSubtitle:"Dein Car-Hifi Spezialist für individuelle Sound-Umbauten. Wähle dein Fahrzeug, entdecke passende Pakete und frag unverbindlich an – wir kümmern uns um den Rest.",stats:[{value:"20+",label:"Jahre Erfahrung"},{value:"Riesige",label:"3D-Druckfarm im eigenen Haus"},{value:"Eigene",label:"CNC- & Laserwerkstatt"},{value:"International",label:"anerkannter Car-Hifi-Spezialist"}],brandsHeading:"Marken, mit denen wir arbeiten",youtubeBadge:"HifiPlanet präsentiert",youtubeTitle:"Das Handwerk hinter deinem Sound",youtubeText:"Entdecke die Handwerkskunst hinter unserer Arbeit",youtubeCta:"Jetzt ansehen",heroImageAlt:"Ground Zero Subwoofer und Endstufen mit violetter Ambiente-Beleuchtung",craftImageAlt:"Individueller Subwoofer-Bau",adviceImageAlt:"Endstufen-Einbau mit Ambiente-Beleuchtung",moreImageAlt:"Hochwertige Endstufe und Subwoofer, Studioaufnahme",craftEyebrow:"Handwerk",craftTitle:"Präzisionsarbeit in jedem Detail",craftText:"Ob eigens gefertigte Subwoofer-Gehäuse, integrierte Beleuchtung oder unsichtbar verlegte Kabelwege – dank eigener CNC-, Laser- und 3D-Druck-Fertigung entstehen bei uns Lösungen, die es von der Stange nicht gibt.",adviceEyebrow:"Beratung",adviceTitle:"Von der ersten Idee bis zum letzten Schliff",adviceText:"Jedes Fahrzeug und jeder Anspruch ist anders. Deshalb beraten wir dich persönlich und unverbindlich – vom dezenten Upgrade bis zum kompromisslosen High-End-System.",insightsTitle:"Einblicke in unsere Umbauten",insightsText:"Vom unauffälligen Sound-Upgrade bis zum aufwendigen Komplettumbau – Handarbeit aus unserer Werkstatt in Amorbach.",galleryAlts:["Individueller Subwoofer-Bau mit Ground Zero Bässen","Endstufen-Einbau mit violetter Ambiente-Beleuchtung","Hochtöner- und Mitteltöner-Einbau von Focal Utopia","Sony Navigationssystem mit Apple CarPlay im Cockpit","Verbauter Hochtöner im Kofferraum","Individueller Subwoofer-Einbau mit LED-Beleuchtung im Kofferraum"],reviewsRating:"5,0 von 181 Kunden bewertet",reviewsRatingDynamic:(e,t)=>`${e.toFixed(1).replace(".",",")} von ${t} Kunden bewertet`,reviewsText:"Das sagen unsere Kunden über uns.",reviewsLink:"Alle Bewertungen auf Google ansehen →",testimonials:[{name:"Thomas K.",text:"Über YouTube auf dieses Klang-Juwel gestoßen. Beratung und Empfehlungen sind erstklassig – der Tesla-Vorführwagen hat meine Leidenschaft für guten Sound neu entfacht."},{name:"Andreas I.",text:"Sehr professionelle Beratung und Service. Obwohl ich von VAG zu Mercedes gewechselt bin, wurde alles reibungslos angepasst. Die 3-Wege-Lautsprecher und zwei Subwoofer liefern außergewöhnliche Leistung."},{name:"Thomas F.",text:"Kompletter Audi A4 B9 Umbau hat meine Erwartungen übertroffen. Von Anfang bis Ende professionell, mit tadelloser Verarbeitung und Klangqualität."},{name:"Drago G.",text:"Beeindruckt von der CNC-Arbeit, die auf YouTube gezeigt wird. Angefangen mit 3D-gedruckten Lautsprecherringen für meinen Ford Mustang – daraus wurde ein viel größeres Projekt."},{name:"Leonardo B.",text:"Toller Service und meisterhafte Handwerkskunst. Saubere Installation, Leidenschaft in jedem Detail erkennbar."},{name:"Marcel S.",text:"Unschlagbares Preis-Leistungs-Verhältnis. Das Team hat sich viel Zeit genommen, um genau die Lösung für mein Budget zu finden."},{name:"Julia W.",text:"Endlich ein Betrieb, der auch Wohnmobile ernst nimmt. Die Soundanlage in unserem Camper klingt jetzt wie im Wohnzimmer."},{name:"Kevin R.",text:"Dashcam und Alarmanlage in einem Termin sauber verbaut, keine sichtbaren Kabel. Absolute Empfehlung für alle, die Wert auf Verarbeitung legen."},{name:"Sabrina H.",text:"Mein Oldtimer hat jetzt modernen Sound, ohne dass es dem Original-Look geschadet hätte. Genau das habe ich gesucht."},{name:"Niklas P.",text:"Von der ersten Anfrage bis zum fertigen Umbau lief alles reibungslos. Ehrliche Beratung ohne Verkaufsdruck."}],moreTitle:"Mehr als nur Car-Hifi",moreText:"Neben individuellen Sound-Umbauten bieten wir CNC-Zerspanung, Lasertechnik, 3D-Druck und mehr – alles aus einer Hand in unserer eigenen Werkstatt.",moreCta:"Alle Leistungen entdecken",faqHeading:"Häufig gestellte Fragen"},vehicleSelect:{loading:"Marken werden geladen…",metaTitle:"Fahrzeug auswählen",metaDescription:"Wähle deine Fahrzeugmarke und dein Modell und entdecke passende Car-Hifi Sound-Pakete von HifiPlanet.",title:"Fahrzeug auswählen",intro:"Wähle zuerst deine Marke, dann dein Modell – wir zeigen dir direkt die passenden Sound-Pakete.",empty:"Es sind noch keine Marken hinterlegt."},brandPage:{metaTitleFallback:"Modell auswählen",metaDescription:e=>`Wähle dein ${e} Modell und entdecke passende Car-Hifi Sound-Pakete von HifiPlanet.`,loading:"Lädt…",breadcrumbVehicles:"Fahrzeuge",titleSuffix:"Modell wählen",empty:"Für diese Marke sind noch keine Modelle hinterlegt."},modelPage:{customRequest:"Individuell anfragen",customHint:"Nicht das Passende dabei? Wir stellen dir gerne ein Paket nach deinen Wünschen zusammen.",whatsappText:(e,t)=>`Hallo HifiPlanet, ich interessiere mich für einen Car-Hifi-Umbau für meinen ${e} ${t}.`,metaTitleFallback:"Sound-Pakete",metaTitle:(e,t)=>`${e} ${t} Sound-Pakete`,metaDescription:(e,t)=>`Car-Hifi Sound-Pakete für ${e} ${t} inkl. aktueller Preise – von HifiPlanet unverbindlich anfragen.`,loading:"Lädt…",breadcrumbVehicles:"Fahrzeuge",titleSuffix:"Sound-Pakete",empty:"Für dieses Modell sind noch keine Pakete hinterlegt.",totalPrice:"ab ca.",productLoading:"Produkt wird geladen…",requestContact:"Kontakt anfragen",badges:{recommended:"Empfohlen",popular:"Am beliebtesten",tip:"Tipp",coming_soon:"Coming soon"},videoLink:"Zum Video",moreBullets:e=>e===1?"+ 1 weitere Leistung":`+ ${e} weitere Leistungen`,showMore:"Mehr anzeigen",lessBullets:"Weniger anzeigen",wheelHint:"Mit dem Mausrad blättern"},leistungen:{metaTitle:"Leistungen",metaDescription:"Car-Hifi, Wohnmobil & Caravan, Oldtimer, CNC-Zerspanung, Lasertechnik, 3D-Druck, Alarmanlagen und Dash Cams – alles aus einer Hand bei HifiPlanet in Amorbach.",title:"Unsere Leistungen",intro:"Von individuellen Sound-Umbauten bis zur eigenen CNC- und 3D-Druck-Fertigung – alles aus einer Hand in unserer Werkstatt in Amorbach.",notListedTitle:"Dein Projekt ist nicht dabei?",notListedText:"Sprich uns einfach an – wir finden gemeinsam die passende Lösung.",contact:"Kontakt aufnehmen"},contactPage:{sendAnother:"Weitere Anfrage senden",vehicleBoxTitle:"Dein Fahrzeug:",privacyPre:"Mit dem Absenden stimmst du zu, dass wir deine Angaben zur Bearbeitung der Anfrage verwenden. Mehr dazu in der ",privacyLink:"Datenschutzerklärung",privacyPost:".",mapIframeTitle:"Standort von HifiPlanet in Amorbach auf Google Maps",whatsappText:(e,t,n)=>`Hallo HifiPlanet, ich interessiere mich für das Paket "${n}" für meinen ${e} ${t}.`,metaTitle:"Kontakt",metaDescription:"Kontaktiere HifiPlanet in Amorbach für dein individuelles Car-Hifi Projekt – wir beraten dich gerne unverbindlich.",title:"Kontakt aufnehmen",heroEyebrow:"Kontakt",heroTitlePre:"Sprich",heroTitleAccent:"mit",heroTitlePost:"uns.",heroSubtitle:"Ob Anlage, Einbau oder Klang-Tuning für dein Fahrzeug — schreib uns, wir melden uns schnellstmöglich zurück.",packageBoxTitle:"Deine Anfrage bezieht sich auf",formTitle:"Anfrage senden",sentTitle:"Anfrage gesendet ✓",sentText:"Danke! Wir melden uns innerhalb eines Werktags bei dir.",contextIntro:"Deine Anfrage bezieht sich auf:",contextBrand:"Marke",contextModel:"Modell",contextPackage:"Paket",contextProduct:"Produkt",packagePrice:"Paketpreis",upgrades:"Upgrades",optionalUpgrades:"Optionale Upgrades",totalWithUpgrades:"Gesamt inkl. Upgrades",nameLabel:"Name *",namePlaceholder:"Max Mustermann",emailLabel:"E-Mail *",emailPlaceholder:"max@mail.de",phoneLabel:"Telefon",phonePlaceholder:"Optional",vinLabel:"Fahrgestellnummer (FIN)",vinPlaceholder:"Optional – hilft bei der Einschätzung",messageLabel:"Nachricht",messagePlaceholder:"Erzähl uns von deinem Projekt – Fahrzeug, Wunschklang, Budget …",requiredHint:"* Pflichtfelder",sending:"Wird gesendet…",submit:"Anfrage senden",cardTitle:"HiFi Planet Amorbach",address:"Adresse",phone:"Telefon",email:"E-Mail",hours:"Öffnungszeiten",hoursWeek:"Mo–Fr: 9:00–18:00 Uhr",hoursSat:"Sa: 10:00–13:00 Uhr",hoursWeekDays:"Mo–Fr",hoursWeekTime:"9:00 – 18:00 Uhr",hoursSatDay:"Sa",hoursSatTime:"10:00 – 13:00 Uhr",directionsTitle:"Anfahrt",mapEmbedName:"Die Google-Maps-Karte",mapOpenChip:"In Maps öffnen",routePlan:"Route planen",featurePremiumTitle:"Premium Klang",featurePremiumSub:"Höchste Qualität",featureGermanyTitle:"Made in Germany",featureGermanySub:"Präzise Handarbeit",featureIndividualTitle:"Individuell",featureIndividualSub:"Maßgeschneiderte Lösungen",featureExpertsTitle:"Experten Team",featureExpertsSub:"Leidenschaft & Know-how"},galleryOverview:{metaTitle:"Bildergalerie",metaDescription:"Einblicke in unsere Car-Hifi Umbauten – nach Marke sortiert. Wähle eine Marke und entdecke die Projekte.",title:"Bildergalerie",intro:"Wähle eine Marke und entdecke unsere Umbauten im Detail.",loading:"Lädt…",empty:"Es sind noch keine Galerie-Marken hinterlegt."},galleryBrandPage:{metaTitleFallback:"Bildergalerie",metaTitle:e=>`${e} Umbauten`,metaDescription:e=>`Einblicke in unsere ${e} Car-Hifi Umbauten.`,loading:"Lädt…",breadcrumbGallery:"Galerie",titleSuffix:"Projekt wählen",empty:"Für diese Marke sind noch keine Projekte hinterlegt."},galleryProjectPage:{ctaTitle:"So etwas für dein Auto?",ctaText:"Erzähl uns von deinem Fahrzeug – wir planen einen ähnlichen Umbau für dich.",ctaButton:"Ähnlichen Umbau anfragen",ctaTopic:e=>`Mich interessiert ein ähnlicher Umbau wie "${e}" aus eurer Galerie.`,metaTitleFallback:"Bildergalerie",metaDescription:e=>`Fotos unseres ${e} Umbaus.`,loading:"Lädt…",breadcrumbGallery:"Galerie",empty:"Für dieses Projekt sind noch keine Fotos hinterlegt.",enlargeImage:"Bild vergrößern"},downloadsPage:{metaTitle:"Downloads",metaDescription:"Dateien und Songs von HifiPlanet zum Anhören und Herunterladen.",title:"Downloads",intro:"Hier stellen wir dir Dateien und Songs bereit – direkt anhören oder herunterladen.",loading:"Lädt…",empty:"Aktuell stehen keine Downloads bereit.",download:"Herunterladen",lockedTitle:"Geschützter Bereich",lockedText:"Bitte gib das Passwort ein, das du von uns bekommen hast.",passwordLabel:"Passwort",unlock:"Freischalten",unlocking:"Wird geprüft…",wrongPassword:"Das Passwort stimmt leider nicht."},errors:{generic:"Da ist etwas schiefgelaufen. Bitte versuche es noch einmal.",network:"Keine Verbindung zum Server. Bitte prüfe deine Internetverbindung.",notFound:"Diese Seite gibt es nicht (mehr).",rateLimited:"Zu viele Anfragen in kurzer Zeit. Bitte versuche es später noch einmal oder ruf uns an.",invalidInput:"Bitte gib deinen Namen und eine gültige E-Mail-Adresse an.",server:"Auf dem Server ist ein Fehler aufgetreten. Bitte versuche es später noch einmal.",maintenance:"Dieser Bereich wird gerade überarbeitet. Bitte schau später wieder vorbei."},notFound:{metaTitle:"Seite nicht gefunden",title:"Diese Seite haben wir nicht gefunden",text:"Vielleicht ist der Link veraltet oder hat einen Tippfehler. Hier geht es direkt weiter:",toVehicles:"Fahrzeug wählen",toContact:"Kontakt aufnehmen",toHome:"Zur Startseite"}},iT={nav:{mainNav:"Main navigation",menu:"Menu",call:"Call",openMenu:"Open menu",closeMenu:"Close menu",close:"Close",adminPanel:"Go to admin panel",vehicles:"Vehicles",services:"Services",gallery:"Gallery",contact:"Contact",whatsapp:"WhatsApp",shop:"Visit shop",downloads:"Downloads"},themeToggle:{label:"Toggle theme"},languageToggle:{label:"Select language"},footer:{routePlan:"Get directions",contactHeading:"Contact",contactForm:"Contact form",hoursHeading:"Opening hours",open:"Open",closed:"Closed",days:{monFri:"Monday – Friday",sat:"Saturday",sun:"Sunday"},copyright:e=>`© ${e} HifiPlanet. All information without guarantee.`,imprint:"Legal notice",privacy:"Privacy",terms:"Terms",downloads:"Downloads",cookieSettings:"Cookie settings"},cookieConsent:{bannerText:"We only use technically necessary cookies. For Google Maps, YouTube videos and analytics cookies we need your additional consent, since data is transferred to Google in that case.",moreInfo:"More details in our",privacyPolicy:"privacy policy",settings:"Settings",onlyNecessary:"Necessary only",acceptAll:"Accept all",modalTitle:"Cookie settings",modalIntro:"Choose which categories you want to allow. More details in our",necessaryTitle:"Necessary",necessaryDesc:"Required to operate the website (e.g. login session, theme and cookie preference). Cannot be disabled.",externalTitle:"External media",externalDesc:"Google Maps and YouTube videos. Loading them transfers data (including your IP address) to Google.",analyticsTitle:"Analytics",analyticsDesc:"Google Analytics helps us understand how the website is used. This transfers data to Google.",cancel:"Cancel",saveSelection:"Save selection"},maintenance:{title:"Under maintenance",defaultMessage:"This area is currently being updated. Please check back shortly.",login:"Log in"},lightbox:{close:"Close",previous:"Previous image",next:"Next image"},home:{metaTitle:"Custom Car-Hifi Installations",metaDescription:"HifiPlanet – your car-hifi specialist in Amorbach, Germany. Choose your make and model, discover matching sound packages and get in touch, no obligation.",stickyCta:"Ready for your sound upgrade?",selectVehicle:"Select vehicle",getInTouch:"Get in touch",welcome:"Welcome to HifiPlanet",heroTitle:"Home of pure Sound",heroSubtitle:"Your car-hifi specialist for custom sound installations. Choose your vehicle, discover the right package and get in touch, no obligation – we take care of the rest.",stats:[{value:"20+",label:"years of experience"},{value:"Huge",label:"in-house 3D print farm"},{value:"In-house",label:"CNC & laser workshop"},{value:"International",label:"recognized car-hifi specialist"}],brandsHeading:"Brands we work with",youtubeBadge:"HifiPlanet presents",youtubeTitle:"The craft behind your sound",youtubeText:"Discover the artistry behind our work",youtubeCta:"Watch now",heroImageAlt:"Ground Zero subwoofer and amplifiers with purple ambient lighting",craftImageAlt:"Custom subwoofer build",adviceImageAlt:"Amplifier installation with ambient lighting",moreImageAlt:"High-end amplifier and subwoofer, studio shot",craftEyebrow:"Craftsmanship",craftTitle:"Precision work in every detail",craftText:"Whether custom-built subwoofer enclosures, integrated lighting or invisibly routed cabling – our own CNC, laser and 3D-printing production means we can build solutions you simply can't buy off the shelf.",adviceEyebrow:"Consultation",adviceTitle:"From the first idea to the final touch",adviceText:"Every vehicle and every requirement is different. That's why we advise you personally and without obligation – from a subtle upgrade to an uncompromising high-end system.",insightsTitle:"A look at our installations",insightsText:"From subtle sound upgrades to elaborate full installations – handcrafted in our workshop in Amorbach.",galleryAlts:["Custom subwoofer build with Ground Zero bass drivers","Amplifier installation with purple ambient lighting","Tweeter and midrange installation by Focal Utopia","Sony navigation system with Apple CarPlay in the cockpit","Installed tweeter in the trunk","Custom subwoofer installation with LED lighting in the trunk"],reviewsRating:"Rated 5.0 by 181 customers",reviewsRatingDynamic:(e,t)=>`Rated ${e.toFixed(1)} by ${t} customers`,reviewsText:"Here's what our customers say about us.",reviewsLink:"See all reviews on Google →",testimonials:[{name:"Thomas K.",text:"Found this gem through YouTube. Advice and recommendations are top-notch – the Tesla demo car reignited my passion for great sound."},{name:"Andreas I.",text:"Very professional advice and service. Even though I switched from VAG to Mercedes, everything was adapted smoothly. The 3-way speakers and two subwoofers deliver outstanding performance."},{name:"Thomas F.",text:"The complete Audi A4 B9 build exceeded my expectations. Professional from start to finish, with flawless workmanship and sound quality."},{name:"Drago G.",text:"Impressed by the CNC work shown on YouTube. Started with 3D-printed speaker rings for my Ford Mustang – it turned into a much bigger project."},{name:"Leonardo B.",text:"Great service and masterful craftsmanship. Clean installation, passion visible in every detail."},{name:"Marcel S.",text:"Unbeatable value for money. The team took a lot of time to find the exact solution for my budget."},{name:"Julia W.",text:"Finally a shop that takes motorhomes seriously too. The sound system in our camper now sounds like a living room."},{name:"Kevin R.",text:"Dash cam and alarm system installed cleanly in a single appointment, no visible cables. Highly recommended for anyone who values quality workmanship."},{name:"Sabrina H.",text:"My classic car now has modern sound without compromising the original look. Exactly what I was looking for."},{name:"Niklas P.",text:"From the first inquiry to the finished build, everything went smoothly. Honest advice with no sales pressure."}],moreTitle:"More than just car-hifi",moreText:"Besides custom sound installations, we also offer CNC machining, laser technology, 3D printing and more – all from a single source in our own workshop.",moreCta:"Discover all our services",faqHeading:"Frequently asked questions"},vehicleSelect:{loading:"Loading brands…",metaTitle:"Select your vehicle",metaDescription:"Choose your vehicle make and model and discover matching car-hifi sound packages from HifiPlanet.",title:"Select your vehicle",intro:"Choose your make first, then your model – we'll show you the matching sound packages right away.",empty:"No brands have been added yet."},brandPage:{metaTitleFallback:"Select a model",metaDescription:e=>`Choose your ${e} model and discover matching car-hifi sound packages from HifiPlanet.`,loading:"Loading…",breadcrumbVehicles:"Vehicles",titleSuffix:"Select a model",empty:"No models have been added for this brand yet."},modelPage:{customRequest:"Request a custom setup",customHint:"Nothing quite right? We will happily put together a package to suit you.",whatsappText:(e,t)=>`Hello HifiPlanet, I am interested in a car audio upgrade for my ${e} ${t}.`,metaTitleFallback:"Sound packages",metaTitle:(e,t)=>`${e} ${t} sound packages`,metaDescription:(e,t)=>`Car-hifi sound packages for the ${e} ${t} including current prices – get in touch with HifiPlanet, no obligation.`,loading:"Loading…",breadcrumbVehicles:"Vehicles",titleSuffix:"Sound packages",empty:"No packages have been added for this model yet.",totalPrice:"from approx.",productLoading:"Loading product…",requestContact:"Request contact",badges:{recommended:"Recommended",popular:"Most popular",tip:"Tip",coming_soon:"Coming soon"},videoLink:"Watch video",moreBullets:e=>e===1?"+ 1 more feature":`+ ${e} more features`,showMore:"Show more",lessBullets:"Show less",wheelHint:"Scroll to browse"},leistungen:{metaTitle:"Services",metaDescription:"Car-hifi, motorhomes & caravans, classic cars, CNC machining, laser technology, 3D printing, alarm systems and dash cams – all from a single source at HifiPlanet in Amorbach.",title:"Our services",intro:"From custom sound installations to our own CNC and 3D-printing production – all from a single source in our workshop in Amorbach.",notListedTitle:"Don't see your project?",notListedText:"Just get in touch – we'll find the right solution together.",contact:"Get in touch"},contactPage:{sendAnother:"Send another request",vehicleBoxTitle:"Your vehicle:",privacyPre:"By sending this form you agree that we use your details to handle your request. Learn more in our ",privacyLink:"privacy policy",privacyPost:".",mapIframeTitle:"HifiPlanet location in Amorbach on Google Maps",whatsappText:(e,t,n)=>`Hello HifiPlanet, I am interested in the "${n}" package for my ${e} ${t}.`,metaTitle:"Contact",metaDescription:"Get in touch with HifiPlanet in Amorbach for your custom car-hifi project – we're happy to advise you, no obligation.",title:"Get in touch",heroEyebrow:"Contact",heroTitlePre:"Talk",heroTitleAccent:"to",heroTitlePost:"us.",heroSubtitle:"Whether it's a system, installation, or sound tuning for your car — write to us, we'll get back to you as soon as possible.",packageBoxTitle:"Your inquiry relates to",formTitle:"Send inquiry",sentTitle:"Inquiry sent ✓",sentText:"Thanks! We'll get back to you within one business day.",contextIntro:"Your inquiry relates to:",contextBrand:"Brand",contextModel:"Model",contextPackage:"Package",contextProduct:"Product",packagePrice:"Package price",upgrades:"Upgrades",optionalUpgrades:"Optional upgrades",totalWithUpgrades:"Total incl. upgrades",nameLabel:"Name *",namePlaceholder:"Max Mustermann",emailLabel:"Email *",emailPlaceholder:"max@mail.de",phoneLabel:"Phone",phonePlaceholder:"Optional",vinLabel:"Vehicle identification number (VIN)",vinPlaceholder:"Optional – helps us assess your vehicle",messageLabel:"Message",messagePlaceholder:"Tell us about your project – vehicle, desired sound, budget …",requiredHint:"* Required fields",sending:"Sending…",submit:"Send inquiry",cardTitle:"HiFi Planet Amorbach",address:"Address",phone:"Phone",email:"Email",hours:"Opening hours",hoursWeek:"Mon–Fri: 9:00 AM–6:00 PM",hoursSat:"Sat: 10:00 AM–1:00 PM",hoursWeekDays:"Mon–Fri",hoursWeekTime:"9:00 AM – 6:00 PM",hoursSatDay:"Sat",hoursSatTime:"10:00 AM – 1:00 PM",directionsTitle:"Directions",mapEmbedName:"The Google Maps map",mapOpenChip:"Open in Maps",routePlan:"Get directions",featurePremiumTitle:"Premium Sound",featurePremiumSub:"Highest quality",featureGermanyTitle:"Made in Germany",featureGermanySub:"Precision craftsmanship",featureIndividualTitle:"Custom-built",featureIndividualSub:"Tailored solutions",featureExpertsTitle:"Expert Team",featureExpertsSub:"Passion & know-how"},galleryOverview:{metaTitle:"Photo gallery",metaDescription:"A look at our car-hifi installations – sorted by brand. Choose a brand and explore the projects.",title:"Photo gallery",intro:"Choose a brand and explore our installations in detail.",loading:"Loading…",empty:"No gallery brands have been added yet."},galleryBrandPage:{metaTitleFallback:"Photo gallery",metaTitle:e=>`${e} installations`,metaDescription:e=>`A look at our ${e} car-hifi installations.`,loading:"Loading…",breadcrumbGallery:"Gallery",titleSuffix:"Select a project",empty:"No projects have been added for this brand yet."},galleryProjectPage:{ctaTitle:"Want something like this for your car?",ctaText:"Tell us about your vehicle and we will plan a similar build for you.",ctaButton:"Request a similar build",ctaTopic:e=>`I am interested in a build similar to "${e}" from your gallery.`,metaTitleFallback:"Photo gallery",metaDescription:e=>`Photos of our ${e} installation.`,loading:"Loading…",breadcrumbGallery:"Gallery",empty:"No photos have been added for this project yet.",enlargeImage:"Enlarge image"},downloadsPage:{metaTitle:"Downloads",metaDescription:"Files and songs from HifiPlanet to listen to and download.",title:"Downloads",intro:"Here you will find files and songs we provide for you – listen right here or download them.",loading:"Loading…",empty:"There are no downloads available right now.",download:"Download",lockedTitle:"Protected area",lockedText:"Please enter the password you received from us.",passwordLabel:"Password",unlock:"Unlock",unlocking:"Checking…",wrongPassword:"Sorry, that password is not correct."},errors:{generic:"Something went wrong. Please try again.",network:"No connection to the server. Please check your internet connection.",notFound:"This page does not exist (anymore).",rateLimited:"Too many requests in a short time. Please try again later or give us a call.",invalidInput:"Please enter your name and a valid email address.",server:"A server error occurred. Please try again later.",maintenance:"This section is being updated. Please check back later."},notFound:{metaTitle:"Page not found",title:"We could not find this page",text:"The link may be outdated or contain a typo. Continue here:",toVehicles:"Choose your vehicle",toContact:"Get in touch",toHome:"Back to the homepage"}},Ji={de:sT,en:iT};function oT(){const e=localStorage.getItem("hifi-lang");return e==="de"||e==="en"?e:(navigator.language||"de").toLowerCase().startsWith("de")?"de":"en"}function $u(e,t){return t.split(".").reduce((n,r)=>n==null?void 0:n[r],e)}const mx=p.createContext({language:"de",setLanguage:()=>{},toggleLanguage:()=>{},t:e=>{const t=$u(Ji.de,e);return t!==void 0?t:e}});function jm({children:e}){const[t,n]=p.useState(oT);p.useEffect(()=>{document.documentElement.setAttribute("lang",t),localStorage.setItem("hifi-lang",t)},[t]);const r=()=>n(i=>i==="de"?"en":"de"),s=i=>{const o=Ji[t]||Ji.de,a=$u(o,i);if(a!==void 0)return a;const u=$u(Ji.de,i);return u!==void 0?u:i};return l.jsx(mx.Provider,{value:{language:t,setLanguage:n,toggleLanguage:r,t:s},children:e})}function rt(){return p.useContext(mx)}function px({overHero:e=!1,forceDark:t=!1}){const{theme:n,toggleTheme:r}=rT(),{t:s}=rt();return l.jsx("button",{onClick:r,"aria-label":s("themeToggle.label"),className:`rounded-full p-2 transition ${e?"text-white hover:bg-white/10":t?"text-neutral-300 hover:bg-neutral-800":"text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,children:n==="dark"?l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"h-5 w-5",children:l.jsx("path",{d:"M12 3a1 1 0 011 1v1a1 1 0 11-2 0V4a1 1 0 011-1zm0 15a5 5 0 100-10 5 5 0 000 10zm9-6a1 1 0 010 2h-1a1 1 0 110-2h1zM4 12a1 1 0 010 2H3a1 1 0 110-2h1zm14.36-7.36a1 1 0 011.42 1.42l-.71.7a1 1 0 11-1.41-1.4l.7-.72zM5.64 18.36a1 1 0 011.41 1.41l-.7.71a1 1 0 11-1.42-1.41l.71-.71zm12.72 0l.71.7a1 1 0 11-1.41 1.42l-.71-.71a1 1 0 011.41-1.41zM6.34 5.64l-.7-.7A1 1 0 117.05 3.5l.7.71A1 1 0 016.34 5.64zM12 6a1 1 0 011-1v0a1 1 0 01-1 1zm0 12a1 1 0 011 1v1a1 1 0 11-2 0v-1a1 1 0 011-1z"})}):l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",className:"h-5 w-5",children:l.jsx("path",{fillRule:"evenodd",d:"M9.53 2.25a.75.75 0 01.19.82 8.25 8.25 0 0011.03 11.03.75.75 0 011.01.99A10.5 10.5 0 1112.9 2.1a.75.75 0 011.63-.85z",clipRule:"evenodd"})})})}const gx=p.createContext(null);function aT({children:e}){const[t,n]=p.useState(null),[r,s]=p.useState(!0);p.useEffect(()=>{ce.get("/auth/me").then(d=>n(d.authenticated===!1?null:d)).catch(()=>n(null)).finally(()=>s(!1))},[]);const i=async(d,f)=>{const h=await ce.post("/auth/login",{username:d,password:f});return h.requires_2fa?{requires2fa:!0}:(n(h),{requires2fa:!1})},o=async d=>{const f=await ce.post("/auth/verify-2fa",{code:d});n(f)},a=async()=>{await ce.post("/auth/logout",{}),n(null)},u=async()=>{const d=await ce.get("/auth/me");n(d.authenticated===!1?null:d)},c=d=>{var f;return!!t&&(t.is_super_admin||((f=t.permissions)==null?void 0:f.includes(d)))};return l.jsx(gx.Provider,{value:{user:t,loading:r,login:i,verifyTwoFactor:o,logout:a,refreshUser:u,hasPermission:c},children:e})}function qr(){return p.useContext(gx)}const jd=p.createContext({phone:"09373 20 62 390",whatsapp:null,contact_email:"info@hifi-planet-amorbach.de",address_street:"Boxbrunner Str. 20a",address_zip:"63916",address_city:"Amorbach",logo_path:null,logo_dark_path:null,business_hours:null,hero_image_path:null,ga_measurement_id:null,gallery_card_text_x:0,gallery_card_text_y:100,site_font:null,page_loader_enabled:1,package_card_width:210,package_card_height:480,vehicle_tile_width:240,vehicle_tile_height:180,hidden_areas:[]}),lT=jd.Provider;function Lt(){return p.useContext(jd)}function ha(){const{hidden_areas:e}=p.useContext(jd);return t=>(e||[]).includes(t)}const Uu="/assets/logo-dark-R-ckaBhx.png",yx=e=>(e||"").replace(/[^\d+]/g,""),Bo=e=>`tel:${yx(e)}`,Pd=(e,t="")=>`https://wa.me/${yx(e).replace(/^0/,"49").replace("+","")}${t?`?text=${encodeURIComponent(t)}`:""}`;function Yt(e,t={}){typeof window>"u"||typeof window.gtag!="function"||window.gtag("event",e,t)}const uT="https://www.audio4cars.de/",Pm=70,cT=500;function dT({className:e}){return l.jsxs("svg",{viewBox:"0 0 3 2",className:e,"aria-hidden":"true",children:[l.jsx("rect",{width:"3",height:"0.667",y:"0",fill:"#000"}),l.jsx("rect",{width:"3",height:"0.667",y:"0.667",fill:"#D00"}),l.jsx("rect",{width:"3",height:"0.666",y:"1.334",fill:"#FFCE00"})]})}function fT({className:e}){return l.jsxs("svg",{viewBox:"0 0 60 30",className:e,"aria-hidden":"true",children:[l.jsx("clipPath",{id:"fgb-t",children:l.jsx("path",{d:"M30,15 h30 v15 z v15 h-30 z h-30 v-15 z v-15 h30 z"})}),l.jsx("path",{d:"M0,0 v30 h60 v-30 z",fill:"#00247d"}),l.jsx("path",{d:"M0,0 L60,30 M60,0 L0,30",stroke:"#fff",strokeWidth:"6"}),l.jsx("path",{d:"M0,0 L60,30 M60,0 L0,30",clipPath:"url(#fgb-t)",stroke:"#cf142b",strokeWidth:"4"}),l.jsx("path",{d:"M30,0 v30 M0,15 h60",stroke:"#fff",strokeWidth:"10"}),l.jsx("path",{d:"M30,0 v30 M0,15 h60",stroke:"#cf142b",strokeWidth:"6"})]})}const ul=[{code:"de",label:"Deutsch",Flag:dT},{code:"en",label:"English",Flag:fT}];function hT({overHero:e=!1}){const{language:t,setLanguage:n,t:r}=rt(),[s,i]=p.useState(!1),o=p.useRef(null),a=ul.find(u=>u.code===t)||ul[0];return p.useEffect(()=>{if(!s)return;const u=d=>{o.current&&!o.current.contains(d.target)&&i(!1)},c=d=>{d.key==="Escape"&&i(!1)};return document.addEventListener("mousedown",u),document.addEventListener("keydown",c),()=>{document.removeEventListener("mousedown",u),document.removeEventListener("keydown",c)}},[s]),l.jsxs("div",{className:"relative",ref:o,children:[l.jsxs("button",{type:"button",onClick:()=>i(u=>!u),"aria-haspopup":"listbox","aria-expanded":s,"aria-label":r("languageToggle.label"),className:`flex items-center gap-1 rounded-full p-1.5 transition ${e?"hover:bg-white/10":"hover:bg-neutral-800"}`,children:[l.jsx("span",{className:`block h-4 w-6 shrink-0 overflow-hidden rounded-[3px] ring-1 ${e?"ring-white/50":"ring-neutral-600"}`,children:l.jsx(a.Flag,{className:"h-full w-full"})}),l.jsx("svg",{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",className:`h-3 w-3 transition-transform ${e?"text-white/70":"text-neutral-400"} ${s?"rotate-180":""}`,children:l.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M5.23 7.21a.75.75 0 011.06.02L10 11.168l3.71-3.938a.75.75 0 111.08 1.04l-4.25 4.5a.75.75 0 01-1.08 0l-4.25-4.5a.75.75 0 01.02-1.06z"})})]}),s&&l.jsx("div",{role:"listbox",className:"absolute right-0 z-50 mt-2 min-w-[9rem] overflow-hidden rounded-lg border border-neutral-700 bg-neutral-900 py-1 shadow-lg",children:ul.map(u=>l.jsxs("button",{type:"button",role:"option","aria-selected":u.code===t,onClick:()=>{n(u.code),i(!1)},className:`flex w-full items-center gap-2 px-3 py-2 text-left text-sm transition hover:bg-neutral-800 ${u.code===t?"font-semibold text-brand-400":"text-neutral-200"}`,children:[l.jsx("span",{className:"block h-4 w-6 shrink-0 overflow-hidden rounded-[3px] ring-1 ring-neutral-600",children:l.jsx(u.Flag,{className:"h-full w-full"})}),u.label]},u.code))})]})}function mT(){const[e,t]=p.useState(!1),[n,r]=p.useState(!1),[s,i]=p.useState(!1),{user:o}=qr(),{phone:a,whatsapp:u,logo_dark_path:c,has_downloads:d}=Lt(),f=ha(),{t:h}=rt(),y=!f("page.vehicles"),x=!f("page.services"),w=!f("page.gallery"),b=d&&!f("page.downloads"),m=3+[y,x,w,b,a,u].filter(Boolean).length,v=nt().pathname==="/",[k,S]=p.useState(!v);p.useEffect(()=>{if(!v){S(!0);return}const Y=()=>S(window.scrollY>24);return Y(),window.addEventListener("scroll",Y,{passive:!0}),()=>window.removeEventListener("scroll",Y)},[v]);const C=v&&!k,P=p.useRef(null),j=p.useRef(null);p.useEffect(()=>{if(!e)return;const Y=document.body.style.overflow;document.body.style.overflow="hidden";const q=setTimeout(()=>{var N,L;return(L=(N=P.current)==null?void 0:N.querySelector("button, a"))==null?void 0:L.focus()},50),le=N=>{if(N.key==="Escape"){t(!1);return}if(N.key!=="Tab"||!P.current)return;const L=[...P.current.querySelectorAll("a[href], button")];if(!L.length)return;const F=L[0],E=L[L.length-1];N.shiftKey&&document.activeElement===F?(N.preventDefault(),E.focus()):!N.shiftKey&&document.activeElement===E&&(N.preventDefault(),F.focus())};return document.addEventListener("keydown",le),()=>{var N;clearTimeout(q),document.body.style.overflow=Y,document.removeEventListener("keydown",le),(N=j.current)==null||N.focus({preventScroll:!0})}},[e]);const M=({isActive:Y})=>`rounded-md px-2.5 py-1.5 text-sm font-semibold transition ${Y?"text-brand-400":C?"text-white/90 hover:text-white":"text-neutral-300 hover:text-white"}`;p.useEffect(()=>{if(e){r(!0);let le;const N=requestAnimationFrame(()=>{le=requestAnimationFrame(()=>i(!0))});return()=>{cancelAnimationFrame(N),le&&cancelAnimationFrame(le)}}i(!1);const Y=cT+(m-1)*Pm,q=setTimeout(()=>r(!1),Y);return()=>clearTimeout(q)},[e,m]);const T=()=>`transition-all duration-500 ease-out ${s?"opacity-100":"opacity-0"}`,O=Y=>({transitionDelay:`${(s?Y:m-1-Y)*Pm}ms`,transform:s?"translateY(0)":"translateY(-140px)"}),G=o&&l.jsx(U,{to:"/admin","aria-label":h("nav.adminPanel"),title:h("nav.adminPanel"),className:`rounded-full p-2 transition ${C?"text-white hover:bg-white/10":"text-neutral-300 hover:bg-neutral-800"}`,children:l.jsx(CC,{className:"h-5 w-5"})});let W=0;const H=()=>O(W++);return l.jsxs("header",{className:`sticky top-0 z-30 border-b transition-colors duration-300 ${C?"border-transparent bg-transparent":"border-neutral-800 bg-neutral-950/90 backdrop-blur"}`,children:[l.jsxs("div",{className:"mx-auto grid max-w-6xl grid-cols-[1fr_auto_1fr] items-center gap-3 px-4 py-3 sm:px-6",children:[l.jsxs("div",{className:"flex items-center justify-self-start",children:[l.jsx("button",{ref:j,onClick:()=>t(!0),"aria-label":h("nav.openMenu"),"aria-expanded":e,"aria-haspopup":"dialog",className:`rounded-md p-2 transition ${C?"text-white hover:bg-white/10":"text-neutral-300 hover:bg-neutral-800"}`,children:l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-6 w-6",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 6h16M4 12h16M4 18h16"})})}),l.jsxs("nav",{"aria-label":h("nav.mainNav"),className:"ml-2 hidden items-center gap-0.5 lg:flex",children:[y&&l.jsx(cs,{to:"/fahrzeuge",className:M,children:h("nav.vehicles")}),x&&l.jsx(cs,{to:"/leistungen",className:M,children:h("nav.services")}),w&&l.jsx(cs,{to:"/galerie",className:M,children:h("nav.gallery")}),l.jsx(cs,{to:"/kontakt",className:M,children:h("nav.contact")})]})]}),l.jsx(U,{to:"/",className:"flex items-center justify-self-center rounded-lg px-2 py-1",children:l.jsx("img",{src:c||Uu,alt:"HifiPlanet",className:"h-14 w-auto sm:h-16"})}),l.jsxs("div",{className:"flex items-center justify-self-end gap-1",children:[a&&l.jsxs("a",{href:Bo(a),onClick:()=>Yt("contact_call"),className:`mr-1 hidden items-center gap-2 rounded-full border px-3.5 py-1.5 text-sm font-semibold transition lg:inline-flex ${C?"border-white/40 text-white hover:bg-white/10":"border-neutral-700 text-neutral-200 hover:bg-neutral-800"}`,children:[l.jsx(Jn,{className:"h-4 w-4"}),a]}),G,!e&&l.jsx(hT,{overHero:C}),l.jsx(px,{overHero:C,forceDark:!0})]})]}),n&&Oc.createPortal(l.jsx("div",{ref:P,role:"dialog","aria-modal":"true","aria-label":h("nav.menu"),className:"fixed inset-0 z-[100] overflow-y-auto text-left backdrop-blur-xl",style:{background:"linear-gradient(135deg, rgba(241,245,249,0.55) 0%, rgba(227,240,207,0.55) 50%, rgba(248,250,252,0.55) 100%)"},children:l.jsxs("div",{className:"relative mx-auto flex min-h-full max-w-6xl flex-col items-start justify-center gap-5 py-24 pl-6 pr-8 sm:pl-8",children:[l.jsxs("button",{onClick:()=>t(!1),"aria-label":h("nav.closeMenu"),className:"absolute left-6 top-8 flex items-center gap-2 text-neutral-600 hover:text-brand-600 sm:left-8 sm:top-[65px]",children:[l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-6 w-6",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 6l12 12M18 6 6 18"})}),l.jsx("span",{className:"text-xs font-semibold uppercase tracking-wide",children:h("nav.close")})]}),y&&l.jsx(U,{to:"/fahrzeuge",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${T()}`,style:H(),children:h("nav.vehicles")}),x&&l.jsx(U,{to:"/leistungen",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${T()}`,style:H(),children:h("nav.services")}),w&&l.jsx(U,{to:"/galerie",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${T()}`,style:H(),children:h("nav.gallery")}),l.jsx(U,{to:"/kontakt",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${T()}`,style:H(),children:h("nav.contact")}),b&&l.jsx(U,{to:"/downloads",onClick:()=>t(!1),className:`text-3xl font-extrabold tracking-tight text-neutral-900 hover:text-brand-600 ${T()}`,style:H(),children:h("nav.downloads")}),l.jsx("div",{className:`h-px w-16 bg-brand-500/60 ${T()}`,style:H()}),a&&l.jsxs("a",{href:Bo(a),onClick:()=>Yt("contact_call"),className:`flex items-center gap-2 text-sm font-semibold uppercase tracking-wide text-neutral-600 hover:text-brand-600 ${T()}`,style:H(),children:[l.jsx(Jn,{className:"h-4 w-4"}),a]}),u&&l.jsxs("a",{href:Pd(u),onClick:()=>Yt("contact_whatsapp"),target:"_blank",rel:"noopener noreferrer",className:`flex items-center gap-2 text-sm font-semibold uppercase tracking-wide text-neutral-600 hover:text-brand-600 ${T()}`,style:H(),children:[l.jsx(fx,{className:"h-4 w-4"}),h("nav.whatsapp")]}),l.jsxs("a",{href:uT,target:"_blank",rel:"noopener noreferrer",className:`flex items-center gap-2 text-sm font-semibold uppercase tracking-wide text-neutral-600 hover:text-brand-600 ${T()}`,style:H(),children:[l.jsx(GC,{className:"h-4 w-4"}),h("nav.shop")]})]})}),document.body)]})}const Cm="hifiplanet-cookie-consent",xx={necessary:!0,external:!1,analytics:!1},vx=p.createContext({consent:xx,decided:!1,settingsOpen:!1,acceptAll:()=>{},rejectNonEssential:()=>{},saveCustom:()=>{},openSettings:()=>{},closeSettings:()=>{}});function pT({children:e}){const[t,n]=p.useState(xx),[r,s]=p.useState(!1),[i,o]=p.useState(!1);p.useEffect(()=>{try{const y=localStorage.getItem(Cm);if(y){const x=JSON.parse(y);n({necessary:!0,external:!!x.external,analytics:!!x.analytics}),s(!0)}}catch{}},[]);const a=p.useCallback(y=>{n(y),s(!0),o(!1),localStorage.setItem(Cm,JSON.stringify({...y,decidedAt:new Date().toISOString()}))},[]),u=p.useCallback(()=>a({necessary:!0,external:!0,analytics:!0}),[a]),c=p.useCallback(()=>a({necessary:!0,external:!1,analytics:!1}),[a]),d=p.useCallback(y=>a({necessary:!0,external:!!y.external,analytics:!!y.analytics}),[a]),f=p.useCallback(()=>o(!0),[]),h=p.useCallback(()=>o(!1),[]);return l.jsx(vx.Provider,{value:{consent:t,decided:r,settingsOpen:i,acceptAll:u,rejectNonEssential:c,saveCustom:d,openSettings:f,closeSettings:h},children:e})}function Yr(){return p.useContext(vx)}const gT=["mon","tue","wed","thu","fri","sat","sun"],yT=["sun","mon","tue","wed","thu","fri","sat"],cl={mon:"Mo",tue:"Di",wed:"Mi",thu:"Do",fri:"Fr",sat:"Sa",sun:"So"};function xT(e){const t=new Date,n=e==null?void 0:e[yT[t.getDay()]];if(!n||n.closed||!n.open||!n.close)return!1;const r=t.getHours()*60+t.getMinutes(),[s,i]=n.open.split(":").map(Number),[o,a]=n.close.split(":").map(Number);return r>=s*60+i&&r{const s=vT(e==null?void 0:e[r])||t,i=n[n.length-1];i&&i.label===s?i.days=`${i.firstLabel}-${cl[r]}`:n.push({key:r,days:cl[r],firstLabel:cl[r],label:s})}),n}const wT=e=>(e||"").replace(/[^\d+]/g,"");function kT(){const{phone:e,contact_email:t,address_street:n,address_zip:r,address_city:s,business_hours:i,has_downloads:o}=Lt(),a=ha(),u=o&&!a("page.downloads"),c=xT(i),{openSettings:d}=Yr(),{pathname:f}=nt(),h=f==="/",{t:y}=rt(),x=[n,[r,s].filter(Boolean).join(" ")].filter(Boolean).join(", "),w=`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(x)}`,b=wx(i,y("footer.closed"));return l.jsxs("footer",{className:`border-t border-neutral-200 bg-neutral-50 py-10 text-sm text-neutral-600 dark:border-neutral-800 dark:bg-neutral-950 dark:text-neutral-300 ${h?"pb-24":""}`,children:[l.jsxs("div",{className:"mx-auto grid max-w-6xl gap-4 px-4 sm:grid-cols-3 sm:px-6",children:[l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"mb-3 flex items-center gap-2",children:[l.jsx(dx,{className:"h-4 w-4 text-brand-500"}),l.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:"HifiPlanet"})]}),n&&l.jsx("p",{children:n}),(r||s)&&l.jsx("p",{children:[r,s].filter(Boolean).join(" ")}),l.jsxs("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"mt-4 flex items-center justify-center gap-1.5 rounded-md bg-brand-500 px-3 py-2 text-xs font-semibold text-white hover:bg-brand-600",children:[l.jsx(VC,{className:"h-3.5 w-3.5"}),y("footer.routePlan")]})]}),l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"mb-3 flex items-center gap-2",children:[l.jsx(Jn,{className:"h-4 w-4 text-brand-500"}),l.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:y("footer.contactHeading")})]}),l.jsx("p",{children:l.jsx("a",{href:`tel:${wT(e)}`,className:"inline-block py-1 hover:text-brand-500",children:e})}),l.jsx("p",{children:l.jsx("a",{href:`mailto:${t}`,className:"inline-block py-1 hover:text-brand-500",children:t})}),l.jsx(U,{to:"/kontakt",className:"mt-4 flex items-center justify-center gap-1.5 rounded-md border border-neutral-300 px-3 py-2 text-xs font-semibold text-neutral-700 hover:border-brand-500 hover:text-brand-600 dark:border-neutral-700 dark:text-neutral-200",children:y("footer.contactForm")})]}),l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-5 dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"mb-3 flex items-center justify-between gap-2",children:[l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsx(cx,{className:"h-4 w-4 text-brand-500"}),l.jsx("p",{className:"font-semibold text-neutral-900 dark:text-white",children:y("footer.hoursHeading")})]}),l.jsxs("span",{className:`flex items-center gap-1.5 rounded-full px-2 py-0.5 text-[11px] font-semibold ${c?"bg-green-100 text-green-700 dark:bg-green-900/40 dark:text-green-300":"bg-neutral-100 text-neutral-500 dark:bg-neutral-800 dark:text-neutral-400"}`,children:[l.jsx("span",{className:`h-1.5 w-1.5 rounded-full ${c?"bg-green-500":"bg-neutral-400"}`}),y(c?"footer.open":"footer.closed")]})]}),l.jsx("dl",{className:"space-y-1.5",children:b.map(m=>l.jsxs("div",{className:"flex items-center justify-between gap-3",children:[l.jsx("dt",{className:"text-neutral-500 dark:text-neutral-400",children:m.days}),l.jsx("dd",{className:"font-medium text-neutral-700 dark:text-neutral-200",children:m.label})]},m.key))})]})]}),l.jsx("div",{className:"mx-auto mt-8 max-w-6xl border-t border-neutral-200 px-4 pt-6 text-center text-xs text-neutral-500 dark:border-neutral-800 dark:text-neutral-400 sm:px-6",children:l.jsxs("p",{className:"flex flex-wrap items-center justify-center gap-x-2 gap-y-1",children:[l.jsx("span",{children:y("footer.copyright")(new Date().getFullYear())}),l.jsx("span",{children:"·"}),l.jsx(U,{to:"/impressum",className:"hover:text-brand-500",children:y("footer.imprint")}),l.jsx("span",{children:"·"}),l.jsx(U,{to:"/datenschutz",className:"hover:text-brand-500",children:y("footer.privacy")}),l.jsx("span",{children:"·"}),l.jsx(U,{to:"/agb",className:"hover:text-brand-500",children:y("footer.terms")}),l.jsx("span",{children:"·"}),u&&l.jsxs(l.Fragment,{children:[l.jsx(U,{to:"/downloads",className:"hover:text-brand-500",children:y("footer.downloads")}),l.jsx("span",{children:"·"})]}),l.jsx("button",{type:"button",onClick:d,className:"hover:text-brand-500",children:y("footer.cookieSettings")})]})})]})}function bT(){const{scrollYProgress:e}=ix(),t=IP(e,{stiffness:200,damping:30,restDelta:.001});return l.jsx(Kt.div,{style:{scaleX:t},className:"fixed left-0 top-0 z-40 h-0.5 w-full origin-left bg-brand-500"})}const ST=()=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",className:"h-10 w-10",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M14.7 6.3a4 4 0 0 0-5.5 4.5L3 17l2 2 6.2-6.2a4 4 0 0 0 4.5-5.5l-2.6 2.6-2-2 2.6-2.6Z"})});function ai({message:e,fullScreen:t=!1}){const{t:n}=rt(),r=l.jsxs("div",{className:"mx-auto max-w-md text-center",children:[l.jsx("div",{className:"mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-brand-100 text-brand-600 dark:bg-brand-900/40 dark:text-brand-400",children:l.jsx(ST,{})}),l.jsx("h1",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:n("maintenance.title")}),l.jsx("p",{className:"text-neutral-600 dark:text-neutral-300",children:e||n("maintenance.defaultMessage")})]});return t?l.jsxs("div",{className:"relative flex min-h-screen items-center justify-center bg-white px-4 dark:bg-neutral-950",children:[r,l.jsxs(U,{to:"/admin/login","aria-label":n("maintenance.login"),title:n("maintenance.login"),className:"fixed bottom-4 right-4 flex items-center gap-2 rounded-full border border-neutral-200 bg-white px-3 py-2 text-sm font-medium text-neutral-600 shadow-sm transition hover:border-brand-500 hover:text-brand-600 dark:border-neutral-800 dark:bg-neutral-900 dark:text-neutral-300 dark:hover:text-brand-400",children:[l.jsx(_C,{className:"h-4 w-4"}),n("maintenance.login")]})]}):l.jsx("div",{className:"mx-auto max-w-6xl px-4 py-20 sm:px-6",children:r})}const Tm=l.jsx(l.Fragment,{children:'Wartungsmodus aktiv – Besucher sehen aktuell eine Wartungsmeldung. Du siehst diese Seite nur, weil du die Berechtigung "Wartungsmodus umgehen" hast.'});function li({inline:e=!1}){return e?l.jsx("div",{className:"mb-8 rounded-lg bg-amber-500 px-4 py-2 text-center text-xs font-semibold text-white",children:Tm}):l.jsx("div",{className:"bg-amber-500 px-4 py-2 text-center text-xs font-semibold text-white",children:Tm})}const Em='a[href], button:not([disabled]), input:not([disabled]), select, textarea, [tabindex]:not([tabindex="-1"])';function kx(e,t,n){p.useEffect(()=>{if(!t)return;const r=document.activeElement,s=document.body.style.overflow;document.body.style.overflow="hidden";const i=setTimeout(()=>{var a,u;return(u=(a=e.current)==null?void 0:a.querySelector(Em))==null?void 0:u.focus()},30),o=a=>{if(a.key==="Escape"){a.stopPropagation(),n==null||n();return}if(a.key!=="Tab"||!e.current)return;const u=[...e.current.querySelectorAll(Em)];if(!u.length)return;const c=u[0],d=u[u.length-1];a.shiftKey&&document.activeElement===c?(a.preventDefault(),d.focus()):!a.shiftKey&&document.activeElement===d&&(a.preventDefault(),c.focus())};return document.addEventListener("keydown",o),()=>{clearTimeout(i),document.body.style.overflow=s,document.removeEventListener("keydown",o),r instanceof HTMLElement&&r.focus({preventScroll:!0})}},[t,e])}function jT({onClose:e}){const{consent:t,saveCustom:n}=Yr(),[r,s]=p.useState(t.external),[i,o]=p.useState(t.analytics),{t:a}=rt(),u=p.useRef(null);return kx(u,!0,e),l.jsx("div",{className:"fixed inset-0 z-[60] flex items-center justify-center bg-black/50 p-4",onClick:e,children:l.jsxs("div",{ref:u,role:"dialog","aria-modal":"true","aria-label":a("cookieConsent.modalTitle"),className:"w-full max-w-md rounded-xl bg-white p-6 dark:bg-neutral-900",onClick:c=>c.stopPropagation(),children:[l.jsx("h2",{className:"mb-1 text-lg font-bold text-neutral-900 dark:text-white",children:a("cookieConsent.modalTitle")}),l.jsxs("p",{className:"mb-4 text-sm text-neutral-600 dark:text-neutral-300",children:[a("cookieConsent.modalIntro")," ",l.jsx(U,{to:"/datenschutz",className:"underline hover:text-brand-500",onClick:e,children:a("cookieConsent.privacyPolicy")}),"."]}),l.jsxs("div",{className:"space-y-3",children:[l.jsxs("div",{className:"flex items-start justify-between gap-3 rounded-lg border border-neutral-200 p-3 dark:border-neutral-700",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-semibold text-neutral-800 dark:text-neutral-100",children:a("cookieConsent.necessaryTitle")}),l.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:a("cookieConsent.necessaryDesc")})]}),l.jsx("input",{type:"checkbox",checked:!0,disabled:!0,className:"mt-1 h-4 w-4 shrink-0"})]}),l.jsxs("div",{className:"flex items-start justify-between gap-3 rounded-lg border border-neutral-200 p-3 dark:border-neutral-700",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-semibold text-neutral-800 dark:text-neutral-100",children:a("cookieConsent.externalTitle")}),l.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:a("cookieConsent.externalDesc")})]}),l.jsx("input",{type:"checkbox",checked:r,onChange:c=>s(c.target.checked),className:"mt-1 h-4 w-4 shrink-0"})]}),l.jsxs("div",{className:"flex items-start justify-between gap-3 rounded-lg border border-neutral-200 p-3 dark:border-neutral-700",children:[l.jsxs("div",{children:[l.jsx("p",{className:"text-sm font-semibold text-neutral-800 dark:text-neutral-100",children:a("cookieConsent.analyticsTitle")}),l.jsx("p",{className:"text-xs text-neutral-500 dark:text-neutral-400",children:a("cookieConsent.analyticsDesc")})]}),l.jsx("input",{type:"checkbox",checked:i,onChange:c=>o(c.target.checked),className:"mt-1 h-4 w-4 shrink-0"})]})]}),l.jsxs("div",{className:"mt-5 flex justify-end gap-2",children:[l.jsx("button",{type:"button",onClick:e,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:a("cookieConsent.cancel")}),l.jsx("button",{type:"button",onClick:()=>n({external:r,analytics:i}),className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:a("cookieConsent.saveSelection")})]})]})})}function PT(){const{decided:e,settingsOpen:t,acceptAll:n,rejectNonEssential:r,openSettings:s,closeSettings:i}=Yr(),{t:o}=rt();return l.jsxs(l.Fragment,{children:[!e&&l.jsx("div",{className:"fixed inset-x-0 bottom-0 z-50 border-t border-neutral-200 bg-white/95 p-4 shadow-lg backdrop-blur dark:border-neutral-800 dark:bg-neutral-900/95 sm:p-5",children:l.jsxs("div",{className:"mx-auto flex max-w-6xl flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[l.jsxs("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:[o("cookieConsent.bannerText")," ",o("cookieConsent.moreInfo")," ",l.jsx(U,{to:"/datenschutz",className:"underline hover:text-brand-500",children:o("cookieConsent.privacyPolicy")}),"."]}),l.jsxs("div",{className:"flex flex-wrap gap-2 sm:shrink-0",children:[l.jsx("button",{type:"button",onClick:s,className:"rounded-md border border-neutral-300 px-3 py-2 text-sm dark:border-neutral-700",children:o("cookieConsent.settings")}),l.jsx("button",{type:"button",onClick:r,className:"rounded-md border border-neutral-300 px-3 py-2 text-sm dark:border-neutral-700",children:o("cookieConsent.onlyNecessary")}),l.jsx("button",{type:"button",onClick:n,className:"rounded-md bg-brand-500 px-3 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:o("cookieConsent.acceptAll")})]})]})}),t&&l.jsx(jT,{onClose:i})]})}function CT(){const{consent:e}=Yr(),{ga_measurement_id:t}=Lt(),n=p.useRef(!1),r=nt();return p.useEffect(()=>{if(!t||!e.analytics||n.current)return;n.current=!0;const s=document.createElement("script");s.src=`https://www.googletagmanager.com/gtag/js?id=${t}`,s.async=!0,document.head.appendChild(s),window.dataLayer=window.dataLayer||[];function i(...o){window.dataLayer.push(o)}window.gtag=i,i("js",new Date),i("config",t,{anonymize_ip:!0,send_page_view:!1})},[t,e.analytics]),p.useEffect(()=>{!n.current||typeof window.gtag!="function"||window.gtag("consent","update",{analytics_storage:e.analytics?"granted":"denied"})},[e.analytics]),p.useEffect(()=>{!e.analytics||typeof window.gtag!="function"||window.gtag("event","page_view",{page_path:r.pathname+r.search,page_location:window.location.href,page_title:document.title})},[r.pathname,r.search,e.analytics,t]),null}const bx=p.createContext({global:{enabled:!1,message:null},services:{enabled:!1,message:null},vehicles:{enabled:!1,message:null},bypass:!1}),TT=bx.Provider;function ma(){return p.useContext(bx)}const Cd=p.createContext({}),ET=Cd.Provider;function er(e,t){const n=e[t];if(!n)return{};const r={};return n.font_family&&(r.fontFamily=n.font_family),n.font_size&&(r.fontSize=n.font_size),n.color&&(r.color=n.color),r}function Be(e){const t=p.useContext(Cd);return er(t,e)}function Td(){return p.useContext(Cd)}const NT=[{label:"Systemschrift",value:""},{label:"Serifenlos (Arial)",value:"Arial, Helvetica, sans-serif"},{label:"Serif (Georgia)",value:'Georgia, "Times New Roman", serif'},{label:"Klassisch (Times New Roman)",value:'"Times New Roman", Times, serif'},{label:"Modern (Verdana)",value:"Verdana, Geneva, sans-serif"},{label:"Schreibmaschine (Courier New)",value:'"Courier New", Courier, monospace'}],Ed=p.createContext({fonts:[],refresh:()=>{}}),Sx=Ed.Provider;function jx(){return p.useContext(Ed).fonts}function MN(){return p.useContext(Ed).refresh}function LN(){const e=jx();return[...NT,...e.map(t=>({label:t.name,value:t.font_family}))]}function _T(e){const t=/\.([a-z0-9]+)$/i.exec(e||"");return t?t[1].toLowerCase():""}const MT={woff2:"woff2",woff:"woff",ttf:"truetype",otf:"opentype"};function Px(){const e=jx();if(e.length===0)return null;const t=e.map(n=>{const r=MT[_T(n.file_path)]||"woff2";return`@font-face { font-family: "${n.font_family}"; src: url("${n.file_path}") format("${r}"); font-display: swap; }`}).join(` -`);return l.jsx("style",{children:t})}const LT=150,AT=300,DT=80,RT=5e3;function IT(){return l.jsx("div",{className:"fixed inset-0 z-[200] flex items-center justify-center bg-white dark:bg-neutral-950",children:l.jsx("div",{className:"h-10 w-10 animate-spin rounded-full border-4 border-neutral-200 border-t-brand-500 dark:border-neutral-800 dark:border-t-brand-500"})})}function VT({enabled:e,children:t}){const n=nt(),[r,s]=p.useState(!e),[i,o]=p.useState(!1),a=p.useRef(null);return p.useLayoutEffect(()=>{const u=a.current;if(!e||!u){s(!0),o(!1);return}s(!1),o(!1);let c=!1,d=0,f=null;const h=new Set,y=setTimeout(()=>{d=Date.now(),o(!0)},LT),x=()=>{s(!0),o(!1)},w=()=>{c=!0,clearTimeout(y),clearTimeout(f),clearTimeout(C),k.disconnect(),S()},b=()=>{if(c)return;w();const P=d?AT-(Date.now()-d):0;P>0?setTimeout(x,P):x()},m=()=>{clearTimeout(f),f=setTimeout(()=>{h.size===0&&$P()===0&&b()},DT)},g=P=>{if(h.has(P)||P.complete||P.getBoundingClientRect().top>=window.innerHeight)return;P.loading==="lazy"&&(P.loading="eager"),h.add(P);const j=()=>{h.delete(P),P.removeEventListener("load",j),P.removeEventListener("error",j),m()};P.addEventListener("load",j),P.addEventListener("error",j)},v=P=>{var j;P.nodeType===1&&(P.tagName==="IMG"&&g(P),(j=P.querySelectorAll)==null||j.call(P,"img").forEach(g))},k=new MutationObserver(P=>{P.forEach(j=>j.addedNodes.forEach(v)),m()});k.observe(u,{childList:!0,subtree:!0});const S=UP(m),C=setTimeout(b,RT);return u.querySelectorAll("img").forEach(g),m(),()=>{c||w()}},[n.pathname,e]),l.jsxs("div",{className:"relative",children:[l.jsx("div",{ref:a,style:e?{visibility:r?"visible":"hidden"}:void 0,children:t}),e&&i&&l.jsx(IT,{})]})}const Cx=[{title:"Seiten",hint:"Ausgeblendete Seiten verschwinden aus dem Menü und leiten Besucher auf die Startseite um.",areas:[{key:"page.vehicles",label:"Fahrzeuge & Pakete",path:"/fahrzeuge"},{key:"page.services",label:"Leistungen",path:"/leistungen"},{key:"page.gallery",label:"Galerie",path:"/galerie"},{key:"page.downloads",label:"Downloads",path:"/downloads",note:"Erscheint ohnehin nur, wenn Downloads hinterlegt sind."}]},{title:"Startseite",hint:"Einzelne Abschnitte der Startseite. Das große Titelbild oben bleibt immer sichtbar.",areas:[{key:"home.stats",label:"Zahlen-Leiste"},{key:"home.partners",label:"Marken / Partner-Logos"},{key:"home.youtube",label:"Video-Abschnitt"},{key:"home.craft",label:"Handwerk & Beratung"},{key:"home.insights",label:"Einblicke (Bilder)"},{key:"home.reviews",label:"Kundenbewertungen"},{key:"home.more",label:'„Mehr als Car-Hifi"'},{key:"home.faq",label:"Häufige Fragen (FAQ)"}]}],FT=Cx[0].areas;function OT(e){if(!e)return null;const t=FT.find(n=>e===n.path||e.startsWith(`${n.path}/`));return t?t.key:null}function Tx(e,t=[]){const n=OT(e);return!!n&&t.includes(n)}const zT=Cx.flatMap(e=>e.areas),BT={global:{enabled:!1,message:null},services:{enabled:!1,message:null},vehicles:{enabled:!1,message:null}},HT={mon:{open:"09:00",close:"18:00",closed:!1},tue:{open:"09:00",close:"18:00",closed:!1},wed:{open:"09:00",close:"18:00",closed:!1},thu:{open:"09:00",close:"18:00",closed:!1},fri:{open:"09:00",close:"18:00",closed:!1},sat:{open:"10:00",close:"13:00",closed:!1},sun:{open:"",close:"",closed:!0}},dl={phone:"09373 20 62 390",whatsapp:null,contact_email:"info@hifi-planet-amorbach.de",address_street:"Boxbrunner Str. 20a",address_zip:"63916",address_city:"Amorbach",logo_path:null,logo_dark_path:null,business_hours:HT,hero_image_path:null,ga_measurement_id:null,package_card_theme:"graphite",package_card_layout:"strip",package_wheel_hint_interval:8,package_card_width:210,package_card_height:480,vehicle_tile_width:240,vehicle_tile_height:180,gallery_card_text_x:0,gallery_card_text_y:100,site_font:null,page_loader_enabled:1,has_downloads:!1,hidden_areas:[],price_note:null,price_note_en:null},$T=["/impressum","/datenschutz","/agb"],Nm="hifi-site-settings",_m="hifi-maintenance";function Mm(e){try{const t=localStorage.getItem(e);return t?JSON.parse(t):null}catch{return null}}function Lm(e,t){try{localStorage.setItem(e,JSON.stringify(t))}catch{}}const UT={mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday",sun:"Sunday"};function WT(e){var n,r,s;const t=document.getElementById("ld-business");if(t)try{const i=JSON.parse(t.textContent),o=(e.phone||"").replace(/[^\d+]/g,"");o&&(i.telephone=o.startsWith("+")?o:`+49${o.replace(/^0/,"")}`),e.contact_email&&(i.email=e.contact_email),i.address={"@type":"PostalAddress",streetAddress:e.address_street||((n=i.address)==null?void 0:n.streetAddress),postalCode:e.address_zip||((r=i.address)==null?void 0:r.postalCode),addressLocality:e.address_city||((s=i.address)==null?void 0:s.addressLocality),addressCountry:"DE"};const a=e.business_hours;a&&typeof a=="object"&&(i.openingHoursSpecification=Object.entries(UT).filter(([u])=>a[u]&&!a[u].closed&&a[u].open&&a[u].close).map(([u,c])=>({"@type":"OpeningHoursSpecification",dayOfWeek:c,opens:a[u].open,closes:a[u].close}))),t.textContent=JSON.stringify(i)}catch{}}function GT(){var b;const[e]=p.useState(()=>Mm(Nm)),[t,n]=p.useState(()=>Mm(_m)),[r,s]=p.useState(()=>e?{...dl,...e}:dl),[i,o]=p.useState(!!e),[a,u]=p.useState({}),[c,d]=p.useState([]),{loading:f,hasPermission:h}=qr(),y=nt();if(p.useEffect(()=>{ce.get("/maintenance").then(m=>{n(m),Lm(_m,m)}).catch(()=>n(m=>m||BT)),ce.get("/site-settings").then(m=>{s({...dl,...m}),Lm(Nm,m)}).catch(()=>{}).finally(()=>o(!0)),ce.get("/text-styles").then(u).catch(()=>{}),ce.get("/custom-fonts").then(d).catch(()=>{})},[]),p.useEffect(()=>{r.site_font?document.documentElement.style.setProperty("--site-font",r.site_font):document.documentElement.style.removeProperty("--site-font")},[r.site_font]),p.useEffect(()=>{i&&WT(r)},[r,i]),t===null||!i||(b=t.global)!=null&&b.enabled&&f)return l.jsx("div",{className:"min-h-screen bg-white dark:bg-neutral-950"});const x=h("maintenance.bypass"),w=$T.includes(y.pathname);return t.global.enabled&&!x&&!w?l.jsx(jm,{children:l.jsx(ai,{message:t.global.message,fullScreen:!0})}):l.jsx(jm,{children:l.jsx(TT,{value:{...t,bypass:x},children:l.jsx(lT,{value:r,children:l.jsx(ET,{value:a,children:l.jsx(Sx,{value:{fonts:c,refresh:()=>{}},children:l.jsxs("div",{className:"page-texture flex min-h-screen flex-col text-neutral-900 dark:text-neutral-100",children:[l.jsx(Px,{}),x&&t.global.enabled&&l.jsx(li,{}),l.jsx(bT,{}),l.jsx(mT,{}),l.jsx("main",{className:"flex-1",children:l.jsx(VT,{enabled:y.pathname!=="/"&&!!r.page_loader_enabled,children:Tx(y.pathname,r.hidden_areas)?l.jsx(Zn,{to:"/",replace:!0}):l.jsx(p.Suspense,{fallback:l.jsx("div",{className:"min-h-[60vh]"}),children:l.jsx(Uc,{})})})}),l.jsx(kT,{}),l.jsx(PT,{}),l.jsx(CT,{})]})})})})})})}const pa=p.createContext({toast:{success:()=>{},error:()=>{},info:()=>{}},setDirty:()=>{},confirmLeave:()=>!0,refreshCounters:()=>{}});let KT=0;function qT({children:e,onRefreshCounters:t}){const[n,r]=p.useState([]),s=p.useRef(new Set),i=p.useCallback(f=>r(h=>h.filter(y=>y.id!==f)),[]),o=p.useCallback((f,h,y={})=>{const x=++KT;return r(w=>[...w.slice(-3),{id:x,type:f,message:h,action:y.action}]),setTimeout(()=>i(x),y.duration||(f==="error"?7e3:3500)),x},[i]),a=p.useMemo(()=>({success:(f,h)=>o("success",f,h),error:(f,h)=>o("error",f,h),info:(f,h)=>o("info",f,h)}),[o]),u=p.useCallback((f,h)=>{h?s.current.add(f):s.current.delete(f)},[]),c=p.useCallback(()=>{if(s.current.size===0)return!0;const f=window.confirm("Du hast ungespeicherte Änderungen. Seite trotzdem verlassen? Die Änderungen gehen dann verloren.");return f&&s.current.clear(),f},[]);p.useEffect(()=>{const f=y=>{s.current.size!==0&&(y.preventDefault(),y.returnValue="")},h=y=>{var b,m;if(s.current.size===0||y.defaultPrevented||y.button!==0)return;const x=(m=(b=y.target).closest)==null?void 0:m.call(b,"a[href]");if(!x||x.target==="_blank"||y.metaKey||y.ctrlKey||y.shiftKey)return;const w=new URL(x.href,window.location.href);w.origin!==window.location.origin||w.pathname===window.location.pathname||c()||(y.preventDefault(),y.stopPropagation())};return window.addEventListener("beforeunload",f),document.addEventListener("click",h,!0),()=>{window.removeEventListener("beforeunload",f),document.removeEventListener("click",h,!0)}},[c]);const d=p.useMemo(()=>({toast:a,setDirty:u,confirmLeave:c,refreshCounters:t||(()=>{})}),[a,u,c,t]);return l.jsxs(pa.Provider,{value:d,children:[e,l.jsx("div",{className:"pointer-events-none fixed bottom-4 right-4 z-[300] flex w-[min(92vw,380px)] flex-col gap-2","aria-live":"polite",children:n.map(f=>l.jsxs("div",{role:f.type==="error"?"alert":"status",className:`pointer-events-auto flex items-start justify-between gap-3 rounded-lg border px-4 py-3 text-sm shadow-lg ${f.type==="error"?"border-red-200 bg-red-50 text-red-800 dark:border-red-900 dark:bg-red-950 dark:text-red-200":f.type==="success"?"border-green-200 bg-green-50 text-green-800 dark:border-green-900 dark:bg-green-950 dark:text-green-200":"border-neutral-200 bg-white text-neutral-800 dark:border-neutral-700 dark:bg-neutral-900 dark:text-neutral-100"}`,children:[l.jsxs("span",{children:[f.type==="success"?"✓ ":"",f.message]}),l.jsxs("span",{className:"flex shrink-0 items-center gap-3",children:[f.action&&l.jsx("button",{type:"button",onClick:()=>{f.action.onClick(),i(f.id)},className:"font-semibold underline",children:f.action.label}),l.jsx("button",{type:"button",onClick:()=>i(f.id),"aria-label":"Meldung schließen",className:"opacity-60 hover:opacity-100",children:"✕"})]})]},f.id))})]})}function AN(){return p.useContext(pa)}function DN(){return p.useContext(pa).toast}function RN(e,t="page"){const{setDirty:n}=p.useContext(pa);p.useEffect(()=>{n(t,!!e)},[e,t,n]),p.useEffect(()=>()=>n(t,!1),[t,n])}const YT=5*60*1e3,XT=30*60*1e3;function ZT(){const{user:e,login:t,verifyTwoFactor:n}=qr(),[r,s]=p.useState(!1),[i,o]=p.useState("credentials"),[a,u]=p.useState((e==null?void 0:e.username)||""),[c,d]=p.useState(""),[f,h]=p.useState(""),[y,x]=p.useState(""),[w,b]=p.useState(!1),m=p.useRef(Date.now()),g=p.useRef(null);if(kx(g,r,()=>{}),p.useEffect(()=>WP(()=>s(!0)),[]),p.useEffect(()=>{const P=()=>{m.current=Date.now()},j=["keydown","pointerdown","scroll"];j.forEach(T=>window.addEventListener(T,P,{passive:!0}));const M=setInterval(()=>{document.hidden||Date.now()-m.current>XT||ce.get("/auth/me").then(T=>{(T==null?void 0:T.authenticated)===!1&&s(!0)}).catch(()=>{})},YT);return()=>{j.forEach(T=>window.removeEventListener(T,P)),clearInterval(M)}},[]),!r)return null;const v=()=>{s(!1),o("credentials"),d(""),h(""),x("")},k=async P=>{P.preventDefault(),b(!0),x("");try{(await t(a,c)).requires2fa?o("code"):v()}catch(j){x(j.message)}finally{b(!1)}},S=async P=>{P.preventDefault(),b(!0),x("");try{await n(f),v()}catch(j){x(j.message)}finally{b(!1)}},C="w-full rounded-md border border-neutral-300 bg-white px-3 py-2 text-sm focus:border-brand-500 focus:outline-none dark:border-neutral-700 dark:bg-neutral-900";return l.jsx("div",{className:"fixed inset-0 z-[400] flex items-center justify-center bg-black/50 p-4",children:l.jsxs("div",{ref:g,role:"dialog","aria-modal":"true","aria-labelledby":"session-expired-title",className:"w-full max-w-sm rounded-xl bg-white p-6 shadow-xl dark:bg-neutral-900",children:[l.jsx("h2",{id:"session-expired-title",className:"mb-1 text-lg font-bold text-neutral-900 dark:text-white",children:"Bitte erneut anmelden"}),l.jsx("p",{className:"mb-4 text-sm text-neutral-500 dark:text-neutral-400",children:"Deine Sitzung ist abgelaufen. Deine Eingaben auf dieser Seite bleiben erhalten – nach dem Anmelden einfach noch einmal speichern."}),i==="credentials"?l.jsxs("form",{onSubmit:k,className:"space-y-3",children:[l.jsx("input",{value:a,onChange:P=>u(P.target.value),required:!0,placeholder:"Benutzername",autoComplete:"username",className:C}),l.jsx("input",{type:"password",value:c,onChange:P=>d(P.target.value),required:!0,placeholder:"Passwort",autoComplete:"current-password",className:C}),y&&l.jsx("p",{className:"text-sm text-red-600",children:y}),l.jsx("button",{type:"submit",disabled:w,className:"w-full rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:w?"Melde an…":"Anmelden"})]}):l.jsxs("form",{onSubmit:S,className:"space-y-3",children:[l.jsx("input",{value:f,onChange:P=>h(P.target.value),required:!0,inputMode:"numeric",autoComplete:"one-time-code",placeholder:"6-stelliger Code aus der App",className:C}),y&&l.jsx("p",{className:"text-sm text-red-600",children:y}),l.jsx("button",{type:"submit",disabled:w,className:"w-full rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600 disabled:opacity-50",children:w?"Prüfe…":"Bestätigen"})]})]})})}const Am="/assets/logo-BNfZDkmN.png",Dm={home:"M3 11.5 12 4l9 7.5M5 10v9a1 1 0 0 0 1 1h4v-6h4v6h4a1 1 0 0 0 1-1v-9",tag:"M4 4h7l9 9-7 7-9-9V4Zm3.5 3.5h.01",car:"M3 13.5 4.5 9A2 2 0 0 1 6.4 7.5h11.2A2 2 0 0 1 19.5 9L21 13.5M3 13.5v4a1 1 0 0 0 1 1h1a1 1 0 0 0 1-1v-1h12v1a1 1 0 0 0 1 1h1a1 1 0 0 0 1-1v-4M3 13.5h18M6.5 16.5h.01M17.5 16.5h.01",box:"M12 3 4 7.5v9L12 21l8-4.5v-9L12 3Zm0 9 8-4.5M12 12v9M12 12 4 7.5",mail:"M4 6h16a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1Zm0 0 8 7 8-7",users:"M16 7a4 4 0 1 1-8 0 4 4 0 0 1 8 0Zm-4 6c-4 0-7 2-7 4.5V19h14v-1.5C19 15 16 13 12 13Z",shield:"M12 3 4 6v6c0 4.5 3.4 7.7 8 9 4.6-1.3 8-4.5 8-9V6l-8-3Zm-1.5 9.5 4-4 1 1-5 5-2.5-2.5 1-1 1.5 1.5Z",lock:"M6 10V8a6 6 0 1 1 12 0v2m-13 0h14a1 1 0 0 1 1 1v9a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-9a1 1 0 0 1 1-1Zm7 5v2",briefcase:"M4 7h16a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V8a1 1 0 0 1 1-1Zm4 0V5a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2M3 12h18",sliders:"M4 6h16M4 6a2 2 0 1 0 4 0 2 2 0 0 0-4 0Zm16 6H4m10 0a2 2 0 1 0 4 0 2 2 0 0 0-4 0ZM4 18h16m-12 0a2 2 0 1 0 4 0 2 2 0 0 0-4 0Z",image:"M4 5h16a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1V6a1 1 0 0 1 1-1Zm2 12 4.5-5.5L14 16l2.5-3L20 17H6ZM8 9.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z",help:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm0-5.5v.01M9.5 9.25a2.5 2.5 0 1 1 3.5 2.29c-.7.32-1 .77-1 1.46v.3",download:"M12 4v11m0 0-4-4m4 4 4-4M5 19h14",gauge:"M4 13a8 8 0 1 1 16 0M12 13l3.5-3.5M6 17h12",inbox:"M3 13h5l1.5 2.5h5L16 13h5M5 5h14l2 8v5a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1v-5l2-8Z",building:"M4 21V5a1 1 0 0 1 1-1h9a1 1 0 0 1 1 1v16M15 9h4a1 1 0 0 1 1 1v11M3 21h18M8 8h3M8 12h3M8 16h3",palette:"M12 3a9 9 0 1 0 0 18c1 0 1.5-.7 1.5-1.5 0-.4-.2-.8-.4-1.1-.3-.3-.4-.7-.4-1.1 0-.8.7-1.5 1.5-1.5H16a5 5 0 0 0 5-5c0-4.4-4-7.8-9-7.8ZM7.5 12h.01M10 7.5h.01M15 7.5h.01",file:"M7 3h7l5 5v12a1 1 0 0 1-1 1H7a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1Zm7 0v5h5M9 13h6M9 17h6",wrench:"M14.5 6.5a4 4 0 0 0-5.3 5.3L4 17l3 3 5.2-5.2a4 4 0 0 0 5.3-5.3l-2.5 2.5-2.5-.5-.5-2.5 2.5-2.5Z",server:"M4 4h16v6H4V4Zm0 10h16v6H4v-6Zm3-7h.01M7 17h.01",globe:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm-9-9h18M12 3c2.5 2.5 3.5 5.5 3.5 9s-1 6.5-3.5 9c-2.5-2.5-3.5-5.5-3.5-9s1-6.5 3.5-9Z",send:"M4 12 20 4l-4 16-4-7-8-1Zm8 1 8-9",refresh:"M20 11a8 8 0 0 0-14.9-3M4 4v4h4m-4 5a8 8 0 0 0 14.9 3M20 20v-4h-4",trash:"M5 7h14M10 11v6m4-6v6M6 7l1 13h10l1-13M9 7V4h6v3",external:"M14 4h6v6m0-6-9 9M19 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V6a1 1 0 0 1 1-1h5",pause:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18Zm-2-12v6m4-6v6"},Rm=({path:e})=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.75",className:"h-5 w-5 shrink-0",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:e})});function QT(){const{logout:e,user:t,hasPermission:n}=qr(),r=oa(),[s,i]=p.useState(!1),[o,a]=p.useState(0),[u,c]=p.useState([]),[d,f]=p.useState([]),[h,y]=p.useState(!1),x=p.useCallback(()=>{n("contact.manage")&&ce.get("/contact").then(S=>a(S.filter(C=>C.status==="new").length)).catch(()=>{}),ce.get("/site-settings").then(S=>f(S.hidden_areas||[])).catch(()=>{}),ce.get("/maintenance").then(S=>{var C;return y(!!((C=S==null?void 0:S.global)!=null&&C.enabled))}).catch(()=>{})},[t==null?void 0:t.id]);p.useEffect(()=>{x();const S=setInterval(x,2*60*1e3);return()=>clearInterval(S)},[x]);const w=zT.filter(S=>d.includes(S.key)).map(S=>S.label),b=()=>ce.get("/custom-fonts").then(c).catch(()=>{});p.useEffect(()=>{b()},[]);const m=[{title:null,links:[{to:"/admin",label:"Übersicht",icon:"gauge",end:!0},{to:"/admin/contact-requests",label:"Anfragen",icon:"inbox",permission:"contact.manage",badge:o}]},{title:"Fahrzeuge & Pakete",links:[{to:"/admin/brands",label:"Fahrzeugmarken",icon:"tag",permission:"brands.manage"},{to:"/admin/models",label:"Modelle",icon:"car",permission:"models.manage"},{to:"/admin/packages",label:"Pakete",icon:"box",permission:"packages.manage"}]},{title:"Website-Inhalte",links:[{to:"/admin/home-sections",label:"Startseite",icon:"home",permission:"content.manage"},{to:"/admin/services",label:"Leistungen",icon:"briefcase",permission:"services.manage"},{to:"/admin/faqs",label:"FAQ",icon:"help",permission:"content.manage"},{to:"/admin/partners",label:"Partner-Logos",icon:"shield",permission:"content.manage"},{to:"/admin/downloads",label:"Downloads",icon:"download",permission:"downloads.manage"}]},{title:"Bildergalerie",links:[{to:"/admin/gallery-brands",label:"Galerie-Marken",icon:"image",permission:"gallery.manage"},{to:"/admin/gallery-projects",label:"Projekte & Fotos",icon:"image",permission:"gallery.manage"}]},{title:"Firma & Aussehen",links:[{to:"/admin/settings/company",label:"Firmendaten",icon:"building",permission:"settings.manage"},{to:"/admin/settings/design",label:"Aussehen",icon:"palette",permission:"settings.manage"},{to:"/admin/settings/legal",label:"Rechtstexte",icon:"file",permission:"settings.manage"},{to:"/admin/settings/maintenance",label:"Wartungsmodus",icon:"pause",permission:"settings.manage"}]},{title:"System (Experten)",links:[{to:"/admin/users",label:"Benutzer",icon:"users",permission:"users.manage"},{to:"/admin/permission-groups",label:"Berechtigungsgruppen",icon:"lock",permission:"permission_groups.manage"},{to:"/admin/settings/email",label:"E-Mail-Versand",icon:"send",permission:"system.admin"},{to:"/admin/settings/google",label:"Google-Dienste",icon:"globe",permission:"system.admin"},{to:"/admin/settings/database",label:"Datenbank",icon:"server",permission:"system.admin"},{to:"/admin/settings/export-import",label:"Export & Import",icon:"download",permission:"system.admin"},{to:"/admin/settings/update",label:"Updates",icon:"refresh",permission:"system.update"},{to:"/admin/settings/reset",label:"Zurücksetzen",icon:"trash",permission:"system.admin"}]},{title:null,links:[{to:"/admin/account",label:"Mein Konto",icon:"lock"}]}].map(S=>({...S,links:S.links.filter(C=>!C.permission||n(C.permission))})).filter(S=>S.links.length>0),g=async()=>{await e(),r("/admin/login")},v=({isActive:S})=>`flex items-center justify-between gap-2 rounded-md px-3 py-2 text-sm font-medium transition ${S?"bg-brand-500 text-white":"text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800"}`,k=({onNavigate:S})=>l.jsx("nav",{className:"space-y-5",children:m.map((C,P)=>l.jsxs("div",{children:[C.title&&l.jsx("p",{className:"mb-1.5 px-3 text-xs font-semibold uppercase tracking-wide text-neutral-400 dark:text-neutral-500",children:C.title}),l.jsx("div",{className:"space-y-1",children:C.links.map(j=>l.jsxs(cs,{to:j.to,end:j.end,className:v,onClick:S,children:[l.jsxs("span",{className:"flex items-center gap-2.5",children:[l.jsx(Rm,{path:Dm[j.icon]}),j.label]}),!!j.badge&&l.jsx("span",{className:"rounded-full bg-red-500 px-2 py-0.5 text-xs font-bold text-white",children:j.badge})]},j.to))})]},P))});return l.jsxs(qT,{onRefreshCounters:x,children:[l.jsx(ZT,{}),l.jsx(Sx,{value:{fonts:u,refresh:b},children:l.jsxs("div",{className:"flex min-h-screen bg-neutral-50 text-neutral-900 dark:bg-neutral-950 dark:text-neutral-100",children:[l.jsx(Px,{}),l.jsxs("aside",{className:"hidden w-60 shrink-0 border-r border-neutral-200 p-4 dark:border-neutral-800 sm:block",children:[l.jsxs("div",{className:"mb-6 flex items-center gap-2 px-3",children:[l.jsxs(U,{to:"/",className:"rounded-lg px-2 py-1",children:[l.jsx("img",{src:Am,alt:"HifiPlanet",className:"h-7 w-auto dark:hidden"}),l.jsx("img",{src:Uu,alt:"HifiPlanet",className:"hidden h-7 w-auto dark:block"})]}),l.jsx("span",{className:"text-sm font-semibold text-neutral-500 dark:text-neutral-400",children:"Admin"})]}),l.jsx(k,{})]}),l.jsxs("div",{className:"flex-1",children:[l.jsxs("header",{className:"border-b border-neutral-200 dark:border-neutral-800",children:[l.jsxs("div",{className:"flex items-center justify-between px-4 py-3 sm:px-6",children:[l.jsxs("div",{className:"flex items-center gap-2 sm:hidden",children:[l.jsx("button",{onClick:()=>i(S=>!S),"aria-label":"Menü öffnen",className:"rounded-md p-2 text-neutral-600 hover:bg-neutral-100 dark:text-neutral-300 dark:hover:bg-neutral-800",children:l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-6 w-6",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 6h16M4 12h16M4 18h16"})})}),l.jsxs(U,{to:"/",className:"rounded-lg px-1.5 py-0.5",children:[l.jsx("img",{src:Am,alt:"HifiPlanet",className:"h-6 w-auto dark:hidden"}),l.jsx("img",{src:Uu,alt:"HifiPlanet",className:"hidden h-6 w-auto dark:block"})]})]}),l.jsxs("p",{className:"hidden text-sm text-neutral-500 dark:text-neutral-400 sm:block",children:["Angemeldet als ",t==null?void 0:t.username,t!=null&&t.is_super_admin?" · Super-Admin":""]}),l.jsxs("div",{className:"flex items-center gap-2",children:[l.jsxs("a",{href:"/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:[l.jsx(Rm,{path:Dm.external}),l.jsx("span",{className:"hidden sm:inline",children:"Website öffnen"})]}),l.jsx(px,{}),l.jsx("button",{onClick:g,className:"rounded-md border border-neutral-300 px-3 py-1.5 text-sm font-medium text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:"Abmelden"})]})]}),s&&l.jsx("div",{className:"border-t border-neutral-200 px-4 py-3 dark:border-neutral-800 sm:hidden",children:l.jsx(k,{onNavigate:()=>i(!1)})})]}),(h||w.length>0)&&l.jsxs("div",{className:"border-b border-amber-200 bg-amber-50 px-4 py-2 text-sm text-amber-900 dark:border-amber-900 dark:bg-amber-950 dark:text-amber-200 sm:px-6",children:[h&&l.jsxs("p",{children:[l.jsx("strong",{children:"Wartungsmodus ist aktiv"})," – Besucher sehen gerade nur die Wartungsseite."," ",n("settings.manage")&&l.jsx(U,{to:"/admin/settings/maintenance",className:"underline",children:"Ändern"})]}),w.length>0&&l.jsxs("p",{children:[l.jsx("strong",{children:"Ausgeblendet für Besucher:"})," ",w.join(", "),"."," ",l.jsx(U,{to:"/admin",className:"underline",children:"Auf der Übersicht ändern"})]})]}),l.jsx("main",{className:"p-4 sm:p-6",children:l.jsx(p.Suspense,{fallback:l.jsx("p",{className:"text-sm text-neutral-400",children:"Lädt…"}),children:l.jsx(Uc,{})})})]})]})})]})}function JT(){const{user:e,loading:t}=qr();return t?l.jsx("div",{className:"flex min-h-screen items-center justify-center text-neutral-500",children:"Lädt…"}):e?l.jsx(Uc,{}):l.jsx(Zn,{to:"/admin/login",replace:!0})}function fe({permission:e,children:t}){const{hasPermission:n}=qr();return(Array.isArray(e)?e:[e]).some(i=>n(i))?t:l.jsxs("div",{className:"rounded-xl border border-neutral-200 bg-white p-8 text-center dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsx("h1",{className:"mb-2 text-lg font-bold text-neutral-900 dark:text-white",children:"Keine Berechtigung"}),l.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400",children:"Du hast keinen Zugriff auf diesen Bereich. Bitte wende dich an einen Administrator, falls du hier Zugriff brauchst."})]})}function eo(e,t,n="name"){if(!t)return;let r=document.head.querySelector(`meta[${n}="${e}"]`);r||(r=document.createElement("meta"),r.setAttribute(n,e),document.head.appendChild(r)),r.setAttribute("content",t)}function eE(e){let t=document.head.querySelector('link[rel="canonical"]');t||(t=document.createElement("link"),t.setAttribute("rel","canonical"),document.head.appendChild(t)),t.setAttribute("href",`https://hifi-planet.de${e}`),eo("og:url",`https://hifi-planet.de${e}`,"property")}function Im(e){let t=document.head.querySelector('meta[name="robots"]');if(!e){t==null||t.remove();return}t||(t=document.createElement("meta"),t.setAttribute("name","robots"),document.head.appendChild(t)),t.setAttribute("content","noindex")}function rr({title:e,description:t,path:n,noindex:r=!1}){p.useEffect(()=>(Im(r),()=>Im(!1)),[r]),p.useEffect(()=>{e&&(document.title=`${e} | HifiPlanet`,eo("og:title",`${e} | HifiPlanet`,"property")),t&&(eo("description",t),eo("og:description",t,"property")),n&&eE(n)},[e,t,n])}const tE=[.16,1,.3,1],Vm={up:{y:40},left:{x:-56},right:{x:56}};function nE(e){return{hidden:{opacity:0,scale:.96,filter:"blur(8px)",...Vm[e]||Vm.up},visible:{opacity:1,scale:1,x:0,y:0,filter:"blur(0px)"}}}const rE={hidden:{x:"-130%"},visible:{x:"230%",transition:{duration:1.1,ease:"easeInOut",delay:.4}}};function ze({children:e,direction:t="up",className:n="",index:r=0,shine:s=!1,style:i}){const o=Math.min(r*.09,.45);return l.jsxs(Kt.div,{className:n,style:{position:"relative",overflow:"hidden",...i},initial:"hidden",whileInView:"visible",viewport:{once:!0,amount:.25,margin:"-100px"},variants:nE(t),transition:{duration:.75,ease:tE,delay:o},children:[e,s&&l.jsx(Kt.div,{"aria-hidden":!0,variants:rE,className:"pointer-events-none absolute inset-y-0 -left-1/3 w-1/3 rotate-12 bg-gradient-to-r from-transparent via-white/40 to-transparent"})]})}function sE({items:e}){const[t,n]=p.useState(null);return l.jsx("div",{className:"divide-y divide-neutral-200 rounded-xl border border-neutral-200 bg-white dark:divide-neutral-800 dark:border-neutral-800 dark:bg-neutral-900",children:e.map((r,s)=>{const i=t===s;return l.jsxs("div",{children:[l.jsxs("button",{onClick:()=>n(i?null:s),className:"flex w-full items-center justify-between gap-4 px-5 py-4 text-left","aria-expanded":i,children:[l.jsx("span",{className:"font-medium text-neutral-900 dark:text-white",children:r.question}),l.jsx(Kt.svg,{animate:{rotate:i?180:0},transition:{duration:.2},xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",className:"h-5 w-5 shrink-0 text-neutral-500",children:l.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m6 9 6 6 6-6"})})]}),l.jsx(rj,{initial:!1,children:i&&l.jsx(Kt.div,{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.25,ease:"easeInOut"},className:"overflow-hidden",children:l.jsx("p",{className:"px-5 pb-4 text-sm text-neutral-600 dark:text-neutral-300",children:r.answer})})})]},r.question)})})}function Ex({count:e=5,className:t="h-4 w-4"}){return l.jsx("div",{className:"flex gap-0.5 text-amber-400",children:Array.from({length:e}).map((n,r)=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",className:t,children:l.jsx("path",{d:"M10 1.5l2.6 5.6 6.1.6-4.6 4.1 1.3 6-5.4-3.1-5.4 3.1 1.3-6-4.6-4.1 6.1-.6L10 1.5z"})},r))})}const iE=70;function oE({testimonials:e}){const t=p.useRef(null),n=p.useRef(null),r=p.useRef({pos:0,half:0,hovering:!1,dragging:!1,dragStartX:0,dragStartPos:0,lastTime:null,rafId:null}).current;p.useLayoutEffect(()=>{const i=n.current,o=window.matchMedia("(prefers-reduced-motion: reduce)").matches,a=()=>{i.style.transform=`translateX(${r.pos}px)`},u=g=>{if(r.half<=0)return g;for(;g>0;)g-=r.half;for(;g<=-r.half;)g+=r.half;return g},c=()=>{r.half=i.scrollWidth/2,r.pos===0?r.pos=-r.half:r.pos=u(r.pos),a()};c();const d=new ResizeObserver(c);d.observe(i);const f=g=>{r.lastTime===null&&(r.lastTime=g);const v=(g-r.lastTime)/1e3;r.lastTime=g,!r.dragging&&!r.hovering&&!o&&(r.pos=u(r.pos+iE*v),a()),r.rafId=requestAnimationFrame(f)};r.rafId=requestAnimationFrame(f);const h=t.current,y=()=>{r.hovering=!0},x=()=>{r.hovering=!1},w=g=>{r.dragging=!0,r.dragStartX=g.clientX,r.dragStartPos=r.pos,h.setPointerCapture(g.pointerId),h.classList.add("cursor-grabbing"),h.classList.remove("cursor-grab")},b=g=>{r.dragging&&(r.pos=u(r.dragStartPos+(g.clientX-r.dragStartX)),a())},m=g=>{r.dragging&&(r.dragging=!1,h.hasPointerCapture(g.pointerId)&&h.releasePointerCapture(g.pointerId),h.classList.remove("cursor-grabbing"),h.classList.add("cursor-grab"))};return h.addEventListener("pointerenter",y),h.addEventListener("pointerleave",x),h.addEventListener("pointerdown",w),h.addEventListener("pointermove",b),h.addEventListener("pointerup",m),h.addEventListener("pointercancel",m),()=>{cancelAnimationFrame(r.rafId),d.disconnect(),h.removeEventListener("pointerenter",y),h.removeEventListener("pointerleave",x),h.removeEventListener("pointerdown",w),h.removeEventListener("pointermove",b),h.removeEventListener("pointerup",m),h.removeEventListener("pointercancel",m)}},[e.length]);const s=[...e,...e];return l.jsx("div",{ref:t,className:"marquee-viewport cursor-grab touch-pan-y select-none overflow-hidden",children:l.jsx("div",{ref:n,className:"marquee-track flex w-max gap-5",children:s.map((i,o)=>l.jsx("div",{className:"w-64 shrink-0 sm:w-72 lg:w-80",children:l.jsxs("div",{className:"relative flex h-full flex-col overflow-hidden rounded-xl border border-neutral-200 bg-white p-6 shadow-sm transition-shadow duration-300 hover:shadow-lg dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsx("svg",{"aria-hidden":"true",viewBox:"0 0 32 24",className:"absolute -right-1 -top-1 h-16 w-16 text-brand-500/10 dark:text-brand-400/10",children:l.jsx("path",{fill:"currentColor",d:"M9.4 0C4.4 3.5 1 9.1 1 15.3 1 20.6 4.3 24 8.4 24c3.8 0 6.6-3 6.6-6.6 0-3.4-2.4-5.9-5.4-5.9-.6 0-1.4.1-1.6.2C8.5 8.5 11.6 4.6 14.6 2.6L9.4 0zm16.5 0c-4.8 3.5-8.3 9.1-8.3 15.3 0 5.3 3.3 8.6 7.5 8.6 3.7 0 6.6-3 6.6-6.6 0-3.4-2.5-5.9-5.4-5.9-.6 0-1.4.1-1.6.2.5-3.3 3.6-7.1 6.7-9.1L25.9 0z"})}),l.jsx(Ex,{className:"relative z-10 mb-3 h-4 w-4",count:i.rating||5}),l.jsxs("p",{className:"relative z-10 mb-4 line-clamp-6 flex-1 text-sm leading-relaxed text-neutral-600 dark:text-neutral-300",children:["„",i.text,'"']}),l.jsxs("div",{className:"relative z-10 mt-auto flex items-center gap-3",children:[i.photo?l.jsx("img",{src:i.photo,alt:"",referrerPolicy:"no-referrer",className:"h-9 w-9 shrink-0 rounded-full object-cover"}):l.jsx("span",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-full bg-brand-100 text-sm font-semibold text-brand-700 dark:bg-brand-900/40 dark:text-brand-300",children:i.name.charAt(0).toUpperCase()}),l.jsx("p",{className:"text-sm font-semibold text-neutral-900 dark:text-white",children:i.name})]})]})},`${i.name}-${o}`))})})}function Fm(e,t,n={x:0,y:0}){const r=Math.max(0,Math.min(100,e==null?n.x:Number(e)||0)),s=Math.max(0,Math.min(100,t==null?n.y:Number(t)||0));return{left:`${r}%`,top:`${s}%`,transform:`translate(-${r}%, -${s}%)`}}const aE="/assets/gallery-dash2-CEVCErVK.webp",Nx="/assets/gallery-amp-purple-CESAKuOf.webp",lE="/assets/gallery-speaker-CUXQZ49Q.webp",_x="/assets/gallery-subs-COSd4seJ.webp",Mx="/assets/gallery-dash-Cg-7v9qo.webp",uE="/assets/hero-trunk-Dp4_JHDh.webp",cE="/assets/gallery-rear-8cIXPC7T.webp",dE="/assets/hero-highlight-Co4f1Kj5.webp",fE="/assets/youtube-hintergrund-BqSbCrLQ.mp4",hE="/assets/youtube-hintergrund-mobil-BolxAIc0.mp4",Li={left:"text-left",center:"text-center",right:"text-right"},mE={left:"",center:"mx-auto",right:"ml-auto"},pE={eyebrow_de:"",eyebrow_en:"",title_de:"",title_en:"",body_html_de:"",body_html_en:"",text_align:"center",text_align_x:50,text_align_y:50,button_label_de:"",button_label_en:"",button_url:"",font_family:null};function Om({label:e,url:t,className:n,style:r}){const{hidden_areas:s}=Lt();return!e||!t||Tx(t,s)?null:t.startsWith("/")?l.jsx(U,{to:t,className:n,style:r,children:e}):l.jsx("a",{href:t,target:"_blank",rel:"noopener noreferrer",className:n,style:r,children:e})}const gE=[{src:_x,width:900,height:600},{src:Nx,width:900,height:600},{src:lE,width:900,height:1200},{src:Mx,width:900,height:814},{src:cE,width:900,height:1200},{src:uE,width:1920,height:1280}];function yE(){const{hero_image_path:e}=Lt(),t=e||aE,{t:n,language:r}=rt(),s=ha(),i=!s("page.vehicles"),o=n("home.stats"),a=n("home.galleryAlts"),u=gE.map((I,$)=>({...I,alt:a[$]})),[c,d]=p.useState([]),[f,h]=p.useState({}),[y,x]=p.useState(!1),[w,b]=p.useState([]),m=I=>{const $=f[I]||pE,V=y&&{hero:n("home.heroTitle"),craft:n("home.craftTitle")}[I]||"",oe=y&&I==="hero"?`

${n("home.heroSubtitle")}

`:"";return{eyebrow:$[`eyebrow_${r}`]||"",title:$[`title_${r}`]||V,bodyHtml:$[`body_html_${r}`]||oe,align:$.text_align||"center",alignX:$.text_align_x,alignY:$.text_align_y,buttonLabel:$[`button_label_${r}`]||"",buttonUrl:$.button_url||"",fontFamily:$.font_family||void 0}},g=Be("home_sections.hero.eyebrow"),v=Be("home_sections.hero.title"),k=Be("home_sections.youtube.eyebrow"),S=Be("home_sections.youtube.title"),C=Be("home_sections.youtube.button_label"),P=Be("home_sections.craft.eyebrow"),j=Be("home_sections.craft.title"),M=Be("home_sections.advice.eyebrow"),T=Be("home_sections.advice.title"),O=Be("home_sections.insights.eyebrow"),G=Be("home_sections.insights.title"),W=Be("home_sections.more.eyebrow"),H=Be("home_sections.more.title"),Y=Be("home_sections.more.button_label");p.useEffect(()=>{ce.get("/home-sections").then(h).catch(()=>x(!0))},[]),p.useEffect(()=>{ce.get("/partners").then(b).catch(()=>{})},[]);const[q,le]=p.useState(null),N=q?q.reviews.filter(I=>I.review_text).map(I=>({name:I.author_name,text:I.review_text,rating:I.rating,photo:I.profile_photo_url})):n("home.testimonials");p.useEffect(()=>{ce.get("/faqs").then(I=>{d(I.map($=>({question:r==="de"?$.question_de:$.question_en,answer:r==="de"?$.answer_de:$.answer_en})))}).catch(()=>{})},[r]),p.useEffect(()=>{ce.get("/google-reviews").then(I=>{I.rating!=null&&I.reviews.some($=>$.review_text)&&le(I)}).catch(()=>{})},[]),rr({title:n("home.metaTitle"),description:n("home.metaDescription"),path:"/"}),p.useEffect(()=>{if(c.length===0||s("home.faq"))return;const I=document.createElement("script");return I.type="application/ld+json",I.text=JSON.stringify({"@context":"https://schema.org","@type":"FAQPage",mainEntity:c.map($=>({"@type":"Question",name:$.question,acceptedAnswer:{"@type":"Answer",text:$.answer}}))}),document.head.appendChild(I),()=>document.head.removeChild(I)},[c]),p.useEffect(()=>{var I;c.length>0&&window.location.hash==="#faq"&&((I=document.getElementById("faq"))==null||I.scrollIntoView())},[c]);const L=p.useRef(null);p.useEffect(()=>{var we,dt,Ln;const I=L.current;if(!I)return;const $=(we=window.matchMedia)==null?void 0:we.call(window,"(prefers-reduced-motion: reduce)").matches,V=(dt=navigator.connection)==null?void 0:dt.saveData;if($||V)return;const Se=((Ln=window.matchMedia)==null?void 0:Ln.call(window,"(max-width: 767px), (pointer: coarse)").matches)?hE:fE,te=new IntersectionObserver(([Lx])=>{Lx.isIntersecting?(I.getAttribute("src")||(I.src=Se),I.play().catch(()=>{})):I.paused||I.pause()},{rootMargin:"300px 0px"});return te.observe(I),()=>te.disconnect()},[]);const F=p.useRef(null),{scrollYProgress:E}=ix({target:F,offset:["start start","end start"]}),A=VP(),se=ln(E,[0,1],A?["0%","0%"]:["-6%","6%"]),z=ln(E,[0,1],A?["0%","0%"]:["0%","60%"]),de=ln(E,[0,.8],[1,0]),ie=ln(E,[.5,1],[0,1]),re=ln(ie,I=>I>.05?"auto":"none"),De=ln(E,[.5,1],[16,0]);return l.jsxs("div",{children:[l.jsx(Kt.div,{style:{opacity:ie,pointerEvents:re,y:De},className:"fixed inset-x-0 bottom-0 z-20 border-t border-neutral-200 bg-white/95 px-4 py-3 shadow-[0_-8px_24px_rgba(0,0,0,0.08)] backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:px-6",children:l.jsxs("div",{className:"mx-auto flex max-w-6xl items-center justify-between gap-3",children:[l.jsx("p",{className:"hidden text-sm font-medium text-neutral-600 dark:text-neutral-300 sm:block",children:n("home.stickyCta")}),l.jsxs("div",{className:"flex w-full gap-3 sm:w-auto",children:[i&&l.jsx(U,{to:"/fahrzeuge",className:"flex-1 rounded-md bg-brand-500 px-5 py-2.5 text-center text-sm font-semibold text-white shadow-sm transition hover:-translate-y-0.5 hover:bg-brand-600 sm:flex-none",children:n("home.selectVehicle")}),l.jsx(U,{to:"/kontakt",className:"flex-1 rounded-md border border-neutral-300 px-5 py-2.5 text-center text-sm font-semibold text-neutral-700 transition hover:-translate-y-0.5 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800 sm:flex-none",children:n("home.getInTouch")})]})]})}),l.jsxs("section",{ref:F,className:"relative -mt-[89px] h-svh min-h-[560px] overflow-hidden sm:-mt-[97px]",children:[l.jsx(Kt.img,{style:{y:se,scale:1.15},src:t,alt:n("home.heroImageAlt"),className:"absolute inset-0 h-full w-full object-cover"}),l.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-neutral-950 via-neutral-950/80 to-neutral-950/40"}),l.jsx(Kt.div,{style:{y:z,opacity:de},className:"absolute inset-0",children:l.jsx("div",{className:"absolute w-full max-w-2xl px-4 text-center sm:px-6",style:{...Fm(m("hero").alignX,m("hero").alignY,{x:50,y:50}),fontFamily:m("hero").fontFamily},children:l.jsxs(Kt.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.7,ease:"easeOut"},children:[m("hero").eyebrow&&l.jsx("p",{className:"mb-3 text-sm font-semibold uppercase tracking-wide text-brand-400",style:g,children:m("hero").eyebrow}),l.jsx("h1",{className:"text-3xl font-extrabold tracking-tight text-white sm:text-5xl",style:v,children:m("hero").title}),l.jsx("div",{className:"legal-content mx-auto mt-4 max-w-2xl text-base text-neutral-200 sm:text-lg",dangerouslySetInnerHTML:{__html:m("hero").bodyHtml}}),l.jsxs("div",{className:"mt-8 flex flex-wrap items-center justify-center gap-3",children:[i&&l.jsx(U,{to:"/fahrzeuge",className:"rounded-md bg-brand-500 px-6 py-3 text-sm font-semibold text-white shadow-sm transition hover:-translate-y-0.5 hover:bg-brand-600 hover:shadow-lg",children:n("home.selectVehicle")}),l.jsx(U,{to:"/kontakt",className:"rounded-md border border-white/30 bg-white/10 px-6 py-3 text-sm font-semibold text-white backdrop-blur transition hover:-translate-y-0.5 hover:bg-white/20",children:n("home.getInTouch")})]})]})})})]}),!s("home.stats")&&l.jsx("section",{className:"border-b border-neutral-200 bg-neutral-950 py-8 dark:border-neutral-800",children:l.jsx("div",{className:"mx-auto grid max-w-6xl grid-cols-2 gap-6 px-4 text-center sm:grid-cols-4 sm:px-6",children:o.map((I,$)=>l.jsxs(ze,{index:$,children:[l.jsx("p",{className:"text-2xl font-extrabold text-brand-400 sm:text-3xl",children:I.value}),l.jsx("p",{className:"text-sm text-neutral-400",children:I.label})]},I.label))})}),!s("home.partners")&&l.jsx("section",{className:"border-b border-neutral-200 py-8 dark:border-neutral-800",children:l.jsxs("div",{className:"mx-auto max-w-6xl px-4 sm:px-6",children:[l.jsx("p",{className:"mb-4 text-center text-xs font-semibold uppercase tracking-wide text-neutral-400",children:n("home.brandsHeading")}),l.jsx("div",{className:"flex flex-wrap items-center justify-center gap-x-8 gap-y-3",children:w.map((I,$)=>l.jsx(ze,{index:$,children:I.logo_path?l.jsx("img",{src:I.logo_path,alt:I.name,className:"h-8 max-w-[8rem] object-contain opacity-70 grayscale transition hover:opacity-100 hover:grayscale-0"}):l.jsx("span",{className:"text-lg font-bold text-neutral-400 dark:text-neutral-600",children:I.name})},I.id))})]})}),!s("home.youtube")&&l.jsxs("section",{className:"relative min-h-[70vh] overflow-hidden sm:min-h-[85vh]",children:[l.jsx("video",{ref:L,loop:!0,muted:!0,playsInline:!0,preload:"none",poster:Mx,className:"absolute inset-0 h-full w-full object-cover"}),l.jsx("div",{className:"absolute inset-0 bg-black/55"}),l.jsx("div",{className:"absolute w-full max-w-3xl px-4 text-center sm:px-6",style:{...Fm(m("youtube").alignX,m("youtube").alignY,{x:50,y:50}),fontFamily:m("youtube").fontFamily},children:l.jsxs(ze,{children:[m("youtube").eyebrow&&l.jsx("p",{className:"mb-4 text-xs font-semibold uppercase tracking-[0.2em] text-neutral-200 sm:text-sm",style:k,children:m("youtube").eyebrow}),l.jsx("h2",{className:"text-3xl font-bold uppercase tracking-wide text-white sm:text-5xl",style:S,children:m("youtube").title}),l.jsx("div",{className:"legal-content mt-4 text-xs font-semibold uppercase tracking-wide text-neutral-200 sm:text-sm",dangerouslySetInnerHTML:{__html:m("youtube").bodyHtml}}),l.jsx(Om,{label:m("youtube").buttonLabel,url:m("youtube").buttonUrl,className:"mt-8 inline-flex items-center justify-center rounded-full bg-white px-8 py-3 text-xs font-bold uppercase tracking-wide text-neutral-900 transition hover:-translate-y-0.5 hover:bg-neutral-100",style:C})]})})]}),!s("home.craft")&&l.jsx("section",{className:"grain-band border-y border-neutral-200 bg-neutral-50 py-16 dark:border-neutral-800 dark:bg-neutral-900/40",children:l.jsxs("div",{className:"mx-auto max-w-6xl space-y-16 overflow-hidden px-4 sm:px-6",children:[l.jsxs("div",{className:"grid items-center gap-8 md:grid-cols-2",children:[l.jsx(ze,{direction:"left",shine:!0,className:"rounded-xl shadow-lg",children:l.jsx("img",{src:_x,alt:n("home.craftImageAlt"),width:900,height:600,className:"w-full rounded-xl object-cover",style:{maxHeight:380}})}),l.jsxs(ze,{direction:"right",index:1,className:Li[m("craft").align],style:{fontFamily:m("craft").fontFamily},children:[m("craft").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:P,children:m("craft").eyebrow}),l.jsx("h2",{className:"mb-3 text-2xl font-bold text-neutral-900 dark:text-white",style:j,children:m("craft").title}),l.jsx("div",{className:"legal-content text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:m("craft").bodyHtml}})]})]}),l.jsxs("div",{className:"grid items-center gap-8 md:grid-cols-2",children:[l.jsxs(ze,{direction:"left",className:`order-2 md:order-1 ${Li[m("advice").align]}`,style:{fontFamily:m("advice").fontFamily},children:[m("advice").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:M,children:m("advice").eyebrow}),l.jsx("h2",{className:"mb-3 text-2xl font-bold text-neutral-900 dark:text-white",style:T,children:m("advice").title}),l.jsx("div",{className:"legal-content text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:m("advice").bodyHtml}})]}),l.jsx(ze,{direction:"right",index:1,shine:!0,className:"order-1 md:order-2 rounded-xl shadow-lg",children:l.jsx("img",{src:Nx,alt:n("home.adviceImageAlt"),width:900,height:600,className:"w-full rounded-xl object-cover",style:{maxHeight:380}})})]})]})}),!s("home.insights")&&l.jsxs("section",{className:"mx-auto max-w-6xl px-4 py-16 sm:px-6",children:[l.jsxs(ze,{className:`mb-8 ${Li[m("insights").align]}`,style:{fontFamily:m("insights").fontFamily},children:[m("insights").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:O,children:m("insights").eyebrow}),l.jsx("h2",{className:"text-2xl font-bold text-neutral-900 dark:text-white",style:G,children:m("insights").title}),l.jsx("div",{className:"legal-content mt-2 text-neutral-600 dark:text-neutral-300",dangerouslySetInnerHTML:{__html:m("insights").bodyHtml}})]}),l.jsx("div",{className:"grid grid-cols-2 gap-3 sm:grid-cols-3",children:u.map((I,$)=>l.jsx(ze,{index:$%3,shine:!0,className:"aspect-square overflow-hidden rounded-xl border border-neutral-200 dark:border-neutral-800",children:l.jsx("img",{src:I.src,alt:I.alt,width:I.width,height:I.height,loading:"lazy",className:"h-full w-full object-cover transition duration-300 hover:scale-105"})},I.src))})]}),!s("home.reviews")&&l.jsx("section",{className:"grain-band border-y border-neutral-200 bg-neutral-50 py-16 dark:border-neutral-800 dark:bg-neutral-900/40",children:l.jsxs("div",{className:"mx-auto max-w-6xl px-4 sm:px-6",children:[l.jsxs(ze,{className:"mb-10 text-center",children:[l.jsx("div",{className:"mb-2 flex items-center justify-center gap-2",children:l.jsx(Ex,{className:"h-6 w-6",count:q?Math.round(q.rating):5})}),l.jsx("h2",{className:"text-2xl font-bold text-neutral-900 dark:text-white",children:q?n("home.reviewsRatingDynamic")(q.rating,q.rating_count):n("home.reviewsRating")}),l.jsx("p",{className:"mt-1 text-neutral-600 dark:text-neutral-300",children:n("home.reviewsText")}),l.jsx("a",{href:"https://www.google.com/maps/search/?api=1&query=Hifi+Planet+Amorbach+Boxbrunner+Stra%C3%9Fe+20a",target:"_blank",rel:"noopener noreferrer",className:"mt-2 inline-block text-sm font-medium text-brand-600 hover:underline dark:text-brand-400",children:n("home.reviewsLink")})]}),l.jsx(ze,{children:l.jsx(oE,{testimonials:N})})]})}),!s("home.more")&&l.jsx("section",{className:"mx-auto max-w-6xl overflow-hidden px-4 py-16 sm:px-6",children:l.jsxs("div",{className:"grid items-center gap-10 md:grid-cols-2",children:[l.jsx(ze,{direction:"left",shine:!0,className:"overflow-hidden rounded-xl shadow-lg",children:l.jsx("img",{src:dE,alt:n("home.moreImageAlt"),width:1600,height:905,className:"h-full w-full object-cover",loading:"lazy"})}),l.jsxs(ze,{direction:"right",index:1,className:`rounded-xl border border-neutral-200 bg-white p-8 shadow-sm dark:border-neutral-800 dark:bg-neutral-900 ${Li[m("more").align]}`,style:{fontFamily:m("more").fontFamily},children:[m("more").eyebrow&&l.jsx("p",{className:"mb-2 text-sm font-semibold uppercase tracking-wide text-brand-600 dark:text-brand-400",style:W,children:m("more").eyebrow}),l.jsx("h2",{className:"mb-3 text-2xl font-bold text-neutral-900 dark:text-white",style:H,children:m("more").title}),l.jsx("div",{className:`legal-content mb-8 max-w-2xl text-neutral-600 dark:text-neutral-300 ${mE[m("more").align]}`,dangerouslySetInnerHTML:{__html:m("more").bodyHtml}}),l.jsx(Om,{label:m("more").buttonLabel,url:m("more").buttonUrl,className:"inline-block rounded-md border border-neutral-300 px-6 py-3 text-sm font-semibold text-neutral-700 transition hover:-translate-y-0.5 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",style:Y})]})]})}),!s("home.faq")&&l.jsx("section",{id:"faq",className:"scroll-mt-20 border-t border-neutral-300 py-16 dark:border-neutral-700",children:l.jsxs("div",{className:"mx-auto max-w-3xl px-4 sm:px-6",children:[l.jsx(ze,{className:"mb-8 text-center",children:l.jsx("h2",{className:"text-2xl font-bold text-neutral-900 dark:text-white",children:n("home.faqHeading")})}),l.jsx(ze,{index:1,children:l.jsx(sE,{items:c})})]})})]})}function ga(e,t){return e?e.code==="rate_limited"||e.status===429?t("errors.rateLimited"):e.code==="invalid_input"||e.status===422?t("errors.invalidInput"):e.status===404?t("errors.notFound"):e.status===503?t("errors.maintenance"):e.status>=500?t("errors.server"):e.status?t("errors.generic"):t("errors.network"):""}function xE(){const[e,t]=p.useState(null),[n,r]=p.useState(null),s=ma(),{t:i}=rt(),o=Td(),{vehicle_tile_width:a,vehicle_tile_height:u}=Lt(),c={width:`${a}px`,height:`${u}px`};return rr({title:i("vehicleSelect.metaTitle"),description:i("vehicleSelect.metaDescription"),path:"/fahrzeuge"}),p.useEffect(()=>{s.vehicles.enabled&&!s.bypass||ce.get("/brands").then(t).catch(d=>r(d))},[s.vehicles.enabled,s.bypass]),s.vehicles.enabled&&!s.bypass?l.jsx(ai,{message:s.vehicles.message}):l.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[s.vehicles.enabled&&s.bypass&&l.jsx(li,{inline:!0}),l.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:i("vehicleSelect.title")}),l.jsx("p",{className:"mb-8 text-neutral-600 dark:text-neutral-300",children:i("vehicleSelect.intro")}),n&&l.jsx("p",{className:"text-red-600",children:typeof n=="string"?n:ga(n,i)}),e===null&&!n&&l.jsx("div",{className:"flex flex-wrap gap-4","aria-busy":"true","aria-label":i("vehicleSelect.loading"),children:Array.from({length:6},(d,f)=>l.jsx("div",{style:c,className:"shrink-0 animate-pulse rounded-xl bg-neutral-200 dark:bg-neutral-800"},f))}),(e==null?void 0:e.length)===0&&!n&&l.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:i("vehicleSelect.empty")}),l.jsx("div",{className:"flex flex-wrap gap-4",children:(e||[]).map(d=>d.image_path?l.jsxs(U,{to:`/fahrzeuge/${d.slug}`,style:c,className:"group relative block shrink-0 overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[l.jsx("img",{src:d.image_path,alt:"",loading:"lazy",decoding:"async",width:a,height:u,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}),l.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),l.jsx("span",{className:"absolute inset-x-0 bottom-0 p-4 text-center text-lg font-extrabold text-white",style:er(o,`brands.${d.id}.name`),children:d.name})]},d.id):l.jsx(U,{to:`/fahrzeuge/${d.slug}`,style:c,className:"flex shrink-0 flex-col items-center justify-center gap-3 rounded-xl border border-neutral-200 bg-white px-6 text-center font-semibold text-neutral-800 shadow-sm transition hover:-translate-y-0.5 hover:border-brand-500 hover:shadow-md dark:border-neutral-800 dark:bg-neutral-900 dark:text-neutral-100",children:l.jsx("span",{style:er(o,`brands.${d.id}.name`),children:d.name})},d.id))})]})}function Nd(){const{t:e}=rt(),{phone:t}=Lt(),n=ha();return rr({title:e("notFound.metaTitle"),noindex:!0}),l.jsxs("div",{className:"mx-auto max-w-2xl px-4 py-20 text-center sm:px-6",children:[l.jsx("p",{className:"text-sm font-semibold uppercase tracking-[4px] text-brand-500",children:"404"}),l.jsx("h1",{className:"mt-3 text-3xl font-bold text-neutral-900 dark:text-white sm:text-4xl",children:e("notFound.title")}),l.jsx("p",{className:"mx-auto mt-4 max-w-md text-neutral-600 dark:text-neutral-300",children:e("notFound.text")}),l.jsxs("div",{className:"mt-10 flex flex-wrap justify-center gap-3",children:[!n("page.vehicles")&&l.jsxs(U,{to:"/fahrzeuge",className:"inline-flex items-center gap-2 rounded-md bg-brand-500 px-5 py-3 text-sm font-semibold text-white shadow-sm hover:bg-brand-600",children:[l.jsx(zo,{className:"h-4 w-4"}),e("notFound.toVehicles")]}),l.jsxs(U,{to:"/kontakt",className:"inline-flex items-center gap-2 rounded-md border border-neutral-300 px-5 py-3 text-sm font-semibold text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:[l.jsx(Hu,{className:"h-4 w-4"}),e("notFound.toContact")]}),t&&l.jsxs("a",{href:Bo(t),className:"inline-flex items-center gap-2 rounded-md border border-neutral-300 px-5 py-3 text-sm font-semibold text-neutral-700 hover:bg-neutral-100 dark:border-neutral-700 dark:text-neutral-200 dark:hover:bg-neutral-800",children:[l.jsx(Jn,{className:"h-4 w-4"}),t]})]}),l.jsx(U,{to:"/",className:"mt-8 inline-block text-sm text-neutral-500 underline hover:text-brand-500",children:e("notFound.toHome")})]})}function vE(){const{brandSlug:e}=$c(),[t,n]=p.useState(null),[r,s]=p.useState(null),i=ma(),{t:o}=rt(),a=Td(),u=Be(t?`brands.${t.brand.id}.name`:""),{vehicle_tile_width:c,vehicle_tile_height:d}=Lt(),f={width:`${c}px`,height:`${d}px`};return p.useEffect(()=>{i.vehicles.enabled&&!i.bypass||ce.get(`/brands/${e}/models`).then(n).catch(h=>s(h))},[e,i.vehicles.enabled,i.bypass]),rr({title:t?`${t.brand.name} ${o("brandPage.titleSuffix")}`:o("brandPage.metaTitleFallback"),description:t?o("brandPage.metaDescription")(t.brand.name):void 0,path:`/fahrzeuge/${e}`}),i.vehicles.enabled&&!i.bypass?l.jsx(ai,{message:i.vehicles.message}):r?r.status===404?l.jsx(Nd,{}):l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:ga(r,o)}):t?l.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[i.vehicles.enabled&&i.bypass&&l.jsx(li,{inline:!0}),l.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[l.jsx(U,{to:"/fahrzeuge",className:"hover:text-brand-500",children:o("brandPage.breadcrumbVehicles")})," / ",l.jsx("span",{style:u,children:t.brand.name})]}),l.jsxs("h1",{className:"mb-8 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:[l.jsx("span",{style:u,children:t.brand.name})," – ",o("brandPage.titleSuffix")]}),t.models.length===0&&l.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:o("brandPage.empty")}),l.jsx("div",{className:"flex flex-wrap gap-4",children:t.models.map(h=>h.image_path?l.jsxs(U,{to:`/fahrzeuge/${e}/${h.slug}`,style:f,className:"group relative block shrink-0 overflow-hidden rounded-xl bg-neutral-900 shadow-sm transition hover:shadow-lg",children:[l.jsx("img",{src:h.image_path,alt:"",loading:"lazy",decoding:"async",width:c,height:d,className:"h-full w-full object-cover transition duration-300 group-hover:scale-105"}),l.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/85 via-black/10 to-transparent transition group-hover:from-black/95"}),l.jsx("span",{className:"absolute inset-x-0 bottom-0 p-4 text-center text-lg font-extrabold text-white",style:er(a,`car_models.${h.id}.name`),children:h.name})]},h.id):l.jsx(U,{to:`/fahrzeuge/${e}/${h.slug}`,style:f,className:"flex shrink-0 flex-col items-center justify-center gap-3 rounded-xl border border-neutral-200 bg-white px-6 text-center font-semibold text-neutral-800 shadow-sm transition hover:-translate-y-0.5 hover:border-brand-500 hover:shadow-md dark:border-neutral-800 dark:bg-neutral-900 dark:text-neutral-100",children:l.jsx("span",{style:er(a,`car_models.${h.id}.name`),children:h.name})},h.id))})]}):l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:o("brandPage.loading")})}function wE({text:e}){return e?e.split(/(\*\*[^*]+\*\*)/g).map((n,r)=>{const s=n.match(/^\*\*([^*]+)\*\*$/);return s?l.jsx("strong",{children:s[1]},r):l.jsx("span",{children:n},r)}):null}const zm="data:image/webp;base64,UklGRmoNAABXRUJQVlA4IF4NAAAQjACdASrgAVYDPlEok0ajoqGhIRK4IHAKCWlu/F+5xDCoDux8VXNtc99B5Uf715Q+k/+V6E/yD7bfvf7tYI7QKys1Pu/n/K9wD+L/0L/aeqHflfZf937AH81/p//N/yXr9f9f+M/yf7c+4D6R/7n+O+BL9d+rb+0f//9yX9VQU+fHDhw4cN7KTkCBAgQIECBAgQIEB8GtgzU5WrVq1atWrVq1atTTWWxGRvDLM5r169evXr169evVcNgPhleRXp06dOnTp06dOnTpUIn65+OKaJVsmzZs2bNmzZs2bNmSyYC6ipEunTp06dOnTp06dOlydZVuN901q1atWrVq1atWrVXZqLYS16JYyeHDhw4cOHDhw4cN4wtQeDaQLgECBAgQIECBAgQIDddB6sEmQB2atWrVq1atWrVq1aq1iYS5JU9iBlzXr169evXr169evXeEPp+8N6OklatWrVq1atWrVq1V3IfqDdZ8CK1AgQIECBAgQIECBBQFoI3bXHSzdGb8+OHDhw4cOHDhw4ZwLNj/Gx48ePHjx48ePHjx5HaZ5q8hFQPLVq1atWrVq1atWrVWlrSSS1atWrVq1atWrVq1VouJ4vs1atWrVq1atWrVqzMNN6naRaj4OHDhw4cOHDhwzggYy8goXr169evXr169evXbAmy3nWg79+/fv379+/fv377Aw+GV3JG24BIkSJEiRIkSJEiRH091sORb3KZK2rVq1atWrVq1atWZgOgxn2g3CECBAgQIECBAgQHwEh4tRYq5WHRSJEiRIkSJEiRIkRmQ4gXd9q0Xa9evXr169evXr169SUP3aSDmqBOfHDhw4cOHDhw4cN/rYXzoW6jx48ePHjx48ePHjwyNgV/F/hRIkSJEiRIkSJEiRGcgeccx2x48ePHjx48ePHjx5+h2DL7y1q1atWrVq1atWrVqrLjxn1+UevXr169evXr169epWz/ixb7G7Fx48ePHjx48ePHjx64Dpo0+TFzjw4cOHDhw4cOHDhwr64/FOVqj1ftlBYsWLFixYsWLFixsB93m6MKtrfi/YePHjx48ePHjx48eGCFP4MdBX+BXbQiRIkSJEiRIkSJEiA+X4/Ne4l0FixYsWLFixYsWLTKZjxkHLs7TTrVq1atWrVq1atWrSGY83Cktx0PPjhw4cOHDhw4cN/7Xmd/H4DxEePHjx48ePHjx48ct7KWpas7p5jy5cuXLly5cuXLlyM+h2/gRIkSJEiRIkSJEiRAPRMs9EnbFixYsWLFixYsWLBwJstxClHwcOHDhw4cOHDhw3+o6GvCGxY8ePHjx48ePHjx45aAayr3BCnnxw4cOHDhw4cOG/2HuJWxIvK1JLZs2bNmzZs2bNmyAMNnZLnTo6dOnTp06dOnTp06Vd0rFPQfnwwCPHjx48ePHjx48eOU7jRhCFUn5bFixYsWLFixYsWKZRr/1LzwcOHDhw4cOHDhw4ZshIGgexQoECBAgQIECBAgQH+hD+jvXr169eu0AAP7/2BA2pStbx3f0LK6/mZcFuZpv73FLTm7GUv07j8lFLoOGX1EwKUHfPc4FImBkAvjxF1E2TgBogJKpQ2lbMv5bOqPckB4PELJo9ZXlMwGup4PkMOtTZPmrbNoaCJqn0H4Bx7A0xA439P5hkMGBnAEfInQIN5UeUIDb3y6tLej2gR8HhJ5XmTsxvmM15ltL5ZwdGmoNeW8NevUVUKqJ8mNngu7ocCsyGYaeYOGGZBBt6rj6bPVKVbxvb8onw6mljAaaxGTz0W+aNPv06kK3qhDe6/uHi8kg2qvjF3njhRMyOJKZzg12h4qOtVgTuKPAMRWYDkgwiRs9iYqcumonNNXvXk3FAk2LO5XnyjtD5sHSUO3pIrztpBvqq+UJzKeIwGBlPwA2NP46tOJxLzbrKeH4SQjt2HAsbrVcQ/b/TgKZGPwaqfGDN+OjqJK3Z9dyCkGGfGKeG1w9+HSZTm/qh052lQEJAcdUX6vm/+sDBxtrfl4Sg8iMcVnDsfTKJpsTYF/vzJ1oQ6/VPyIX1HpDwnPXsptu9rKDFazlkwc3ofi8uKJmycgPiG9xOLlzn4Af8Dm+LcjJUMAtA7XeZPLlW1bwogbRthU8oA4LcURuku6eXDJ1eb1IKUU7k/UK0cBeK+R5YVcmrOnZIyHzcIaClYnrIwerP535fHv4VXjURTO6/85BvSeTNWvQGqkW5v1hG6AEMrxBryfat3kmr+SNEz5wC2f54z1O7C2KsRpt3maISh9PhMg7jDIxmVe07eHtkLtz6v3yQUJQV95yazDYpH5JfpuYSb8dtmB1cKjeoDTPvik9dCA1UFCTZBfojpIOwXdwAR7JEdZkEi/24hMNKJJlB6udZZKqNJB1hNl24Z++z6lAGSAuRgSwDZGdbqxs+0iL6wmRHilqPOiYB6hQiPZ7cfpMZxesqRwyhcf1O29w4ORG/7BlerR8hYvY4B1XsPYbDORvPk6FHIDXwTXGpuDIta7G4F6RNDdOvCFkAl53GZo5h/p2QkWUry5YuyegnPlKjT3He6ewYypA9YOvMhaqip7kr9sF4TU2bX9foKZ+FFZNzhyySS+13+g4BdJo9YF3bw5b6eSxUfTWiDLNh50VjuqRQWHUEkiA8zJqnqkKCwuDy6iY2oF20FJQlGIPpCDKPBzdXSb/n9NDltaoUlbam7cDAU7CwNdaWFXTABRk0S0e49iF4tO106Uwul7DGYpq0Eu71TnKUjCtEBc83QH8skvRzHniEne3AtJLYRH0cMNSSzeCJ1g+Nfc8RaZkhLhCaZGZdYe5j0LGmQnVFt2iapZvGBi7Sw0X56zdziC9Foq0OPsqKFetZdICc2eUV5Vu1+nvisSzn8wlSDUt3OmRkt/gJxfJQfWxcu5HZ26qqNpA4ablWrX4E9DEmvXzpFGYCnYJMheN2BlWwBVLh1cyQ8INngXaoB8I5Pj9oYyuz/W+jvJQ6G074luX9D3pLkuc88D0Hae3ZqXrRYRzGF1vD8pHsk9Co8B6rpE/4GEwW/zsCtnjz5G8m4KFwf2qW1k0HkNv7Nlg38bcz6TdTzuw/jega5XZQQhflLu4I6l+s90BHFIR+JEXTBBqJwT+IgTnpHNc+h5Ek74HiKqXuGUNGIKIozHkiFxMlnrsklrpweBzYY6ype9CzepAuQF63xC/eIJw1pMZEC1pPgq/r+1gWx5M6g8fpu2O12sb6pLeqT+G4mK3yHMZTojfp1xwQedRmwZnWQ8SCh4XV2a/+3OTz4D4pmmumyBV7V2VW3he8y6usinSjfYPxLyTng27fgw6jQhHl2mVhxBBjiwr5ljvJV7L+MJYDiZjGWfBCsTmehk6rbNt7ahTJpHu4B9ctRqiZXjx0zGpTF91OKifmy4nTq31p1XaIsZAHCWvItXKeke06KKKRTIm6mCT9yBJVwG1sqQhjrkP77q0/JGYgOwgdCQCstsAZQ0FlOrGYXYTIQK/krLyCAZjg8vP/Ers/KVN8F88OsyU5/T1e5ba8A2F63qgwhtkWoVIEZErOVL8sM/DtpWTlcBNsvVOFl4tT+Sk6a2ScCptFL5F6cZXTIw8JmgoCbyqB6xyU+uPP5y09s5T8MDC7Em7NpxCjgD39eed40gHQrBm6CtAbS9JOCVPkPxbpcGDj/LoAGbnyYzMpOmTi28LJ9FTIqyGuAI0jxY/QpNelOOEvNK3io1HeYkK3AprImDk99tlUjgt9bc3ejCOFDXt9LqGHjFssGrhVHyJBmWjwHQipcIMHxF2jfP5jfAGuHtJRRncHIFgLWmJ1XmzJ0LLqWCJShdJSJLc7L6YeVcgKfzOZCwhtzJ7VeI3uBhPXQNOqCf5tlQ32HApAMvCIiBwhYrpfFo/kvjfTMB/NJ0w2Lk8GAFfFQY+U6uX1oB0hztGmA5HggJTwgLo8exG64m3Xu4fg2g4MmQol7z6xNwwubABnpoS3Og85giFkaarUP2ovQyixFpXki8Xf5a5NwjUGCPbx+LD3WKJiBtkiHsYMMV/VAZVNvdg/Ph/V4ZYOr+hw7g9mOJXi+oVZxG9pqJC9w8nRkegsnQ2lpRHn22lTsIa9aOkR0X8zp/IajQxUzv057a3WptBst0EZbZtfmWp6h2K0sDQS9oQT1PqOkGDJlz6ZHZzDMShDTcwJfIZMdnjpeHdPoYoqlcn3M8daRuMeTSP3mabP1/pdQrs6Wl7ToKog2Au/gv46pUMgVcKmdWNJdDF8RplMMXJpU2tZMdkTWq4ofSypsCfuWfeHOpFQGJdFF6OoH2pDJXvkqpj1a832g3uYtVQg1TGyqYqI7UBZQy4NEZbdj6O/s6MNEnfujUDQ8QZj7rSE2RI77egKDWzM708AsvlMFoeX4CVP09rMzXNP2aOZwY7zOBTvBgEEqCWlXAFlY8pW0zIm16gqSPiwRUgH41i1PuJx382C0zTWGT243ZhLnyOIlreUrMQAfwR/oYt+ljnDFKqa5PEczDPa+u/vWmR6UM+Q/lLFiIlgBJTfaekWoeLpPd9FPN4gIHzK1ZS8kDHyq3lh/e6FQ84a4Zg6JlfQC/qhAAAAA==",kE="/assets/base-BKOm0Bib.webp",bE="/assets/clear-DZZMSrMX.webp",SE="/assets/drive-BE2W1yna.webp",jE="/assets/prime-BTVNe2Gb.webp",PE="/assets/elite_r-BRvz_pyr.webp",CE="/assets/apex-CFy2qup8.webp",TE="/assets/statement-pTO-wTPx.webp",EE="/assets/limitless-DDs0S_PU.webp";function jn(e,t,n){if(!e)return"";if(n==="en"){const r=e[`${t}_en`];if(r)return r}return e[t]}const NE=(e,t,n)=>{t/=100,n/=100;const r=o=>(o+e/30)%12,s=t*Math.min(n,1-n),i=o=>n-s*Math.max(-1,Math.min(r(o)-3,Math.min(9-r(o),1)));return[Math.round(i(0)*255),Math.round(i(8)*255),Math.round(i(4)*255)]},fl=(e,t,n)=>`rgb(${NE(e,t,n).join(", ")})`,Bm=e=>e.map(([t,n,r,s,i,o])=>({bgTop:fl(t,n,r),border:fl(t,n,r+8),accent:fl(s,i,o),img:null})),Hm={graphite:[{accent:"#b6b6b6",border:"#2a2a2a",bgTop:"#1c1c1c",img:kE},{accent:"#d3d3d3",border:"#2e2e2e",bgTop:"#212121",img:bE},{accent:"#8fb8bd",border:"#26383b",bgTop:"#16282b",img:SE},{accent:"#6fbf73",border:"#1f3a24",bgTop:"#122916",img:jE},{accent:"#63d34f",border:"#204a1c",bgTop:"#123312",img:PE},{accent:"#8bea3c",border:"#2b5518",bgTop:"#173a0f",img:CE},{accent:"#d9a83c",border:"#4a3a16",bgTop:"#33270d",img:TE},{accent:"#f2c14e",border:"#5a4718",bgTop:"#3d2f0c",img:EE}],"deep-blue":Bm([[215,18,11,210,15,60],[212,25,11,208,32,60],[210,38,12,206,46,60],[212,46,12,205,56,61],[214,52,12,205,63,62],[216,58,12,205,68,63],[220,62,12,212,73,65],[226,66,12,216,78,68]]),"warm-bronze":Bm([[30,15,11,34,22,60],[34,32,11,34,46,60],[32,46,12,30,58,60],[26,52,12,24,65,60],[20,55,12,18,68,60],[14,55,12,12,68,61],[8,52,12,6,64,62],[2,50,12,358,60,63]])},_E="#f2f2f2",$m="#8a8a8a",ME="#c4c4c4",Um=5,LE=3,AE={recommended:{Icon:qC,className:"bg-brand-500 text-white"},popular:{Icon:jC,className:"bg-amber-400 text-neutral-950"},tip:{Icon:EC,className:"bg-sky-500 text-white"},coming_soon:{Icon:cx,className:"bg-white text-neutral-900"},custom:{Icon:null,className:"bg-brand-500 text-white"}};function DE({pkg:e,tier:t,tierT:n,layout:r,bullets:s,formatPrice:i,contactUrl:o,priceNote:a,t:u}){const[c,d]=p.useState(!1),[f,h]=p.useState(!1),y=p.useRef(null),x=s.length-Um,w=c?s:s.slice(0,Um);p.useLayoutEffect(()=>{const j=y.current;if(!j||c){h(!1);return}const M=()=>h([...j.querySelectorAll("[data-clamp]")].some(O=>O.scrollHeight>O.clientHeight+1));M();const T=new ResizeObserver(M);return T.observe(j),()=>T.disconnect()},[c,s.length,e.description]);const b=Td(),m=er(b,`packages.${e.id}.description`),g=er(b,`packages.${e.id}.price_text`),{package_card_height:v}=Lt(),k=AE[e.badge],S=r!=="grid",C=e.badge==="custom"?e.badge_text:e.badge&&u(`modelPage.badges.${e.badge}`),P=t.img?null:{backgroundColor:t.accent,WebkitMaskImage:`url(${zm})`,maskImage:`url(${zm})`,maskMode:"luminance",WebkitMaskSize:"cover",maskSize:"cover",WebkitMaskPosition:"center",maskPosition:"center",WebkitMaskRepeat:"no-repeat",maskRepeat:"no-repeat"};return l.jsxs("div",{style:{borderColor:t.border,background:`linear-gradient(180deg, ${t.bgTop} 0%, #0b0b0b 55%, #080808 100%)`,...S?{gridRow:"span 4",gridTemplateRows:"subgrid",rowGap:0}:{minHeight:`${v}px`}},className:r==="strip"?"relative grid snap-start overflow-hidden rounded-[18px] border shadow-xl shadow-neutral-900/20 dark:shadow-black/40":r==="coverflow"?"relative grid snap-center overflow-hidden rounded-[18px] border shadow-xl shadow-neutral-900/20 will-change-transform dark:shadow-black/40":"relative flex flex-col overflow-hidden rounded-[18px] border shadow-xl shadow-neutral-900/20 dark:shadow-black/40",children:[t.img?l.jsx("img",{src:t.img,alt:"","aria-hidden":"true",className:"pointer-events-none absolute inset-0 h-full w-full object-cover"}):l.jsxs(l.Fragment,{children:[l.jsx("div",{className:"pointer-events-none absolute inset-0",style:{...P,opacity:.2+n*.45,filter:"blur(18px)"},"aria-hidden":"true"}),l.jsx("div",{className:"pointer-events-none absolute inset-0",style:{...P,opacity:.55+n*.45},"aria-hidden":"true"})]}),k&&C&&l.jsxs("span",{className:`absolute top-2 left-1/2 z-10 flex max-w-[calc(100%-16px)] -translate-x-1/2 items-center gap-1 whitespace-nowrap rounded-full px-3 py-1 text-xs font-bold shadow ${k.className}`,children:[k.Icon&&l.jsx(k.Icon,{className:"h-3.5 w-3.5 shrink-0","aria-hidden":"true"}),l.jsx("span",{className:"truncate",children:C})]}),l.jsxs("div",{className:"relative z-10 text-center",style:{padding:"34px 20px 0",gridRow:1},children:[l.jsx("div",{style:{fontFamily:"'Barlow Condensed', sans-serif",fontSize:"30px",letterSpacing:"3px",fontWeight:600,color:t.accent,textTransform:"uppercase",lineHeight:1.1},children:e.name}),l.jsx("div",{style:{width:"44px",height:"2px",margin:"14px auto 0",background:`linear-gradient(90deg, rgba(255,255,255,0) 0%, ${t.accent} 50%, rgba(255,255,255,0) 100%)`}})]}),s.length>0&&l.jsxs("div",{className:"relative z-10",style:{gridRow:2,padding:"18px 20px 14px",background:c?"linear-gradient(180deg, rgba(8,8,8,0.7) 0%, rgba(8,8,8,0.62) 94%, rgba(8,8,8,0) 100%)":"linear-gradient(180deg, rgba(8,8,8,0.55) 0%, rgba(8,8,8,0.48) 92%, rgba(8,8,8,0) 100%)"},children:[l.jsx("ul",{ref:y,className:"space-y-1.5 text-left",children:w.map((j,M)=>l.jsxs("li",{className:"flex items-start gap-2",style:{fontSize:"13px",color:ME,...j.fromDescription?m:null},children:[l.jsx(aC,{className:"mt-0.5 h-3.5 w-3.5 shrink-0",style:{color:t.accent}}),l.jsx("span",{"data-clamp":!0,className:"leading-snug",style:c?void 0:{display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:LE,overflow:"hidden"},children:j.fromDescription?l.jsx(wE,{text:j.text}):j.text})]},M))}),(c||x>0||f)&&l.jsxs("button",{type:"button",onClick:()=>d(j=>!j),className:"mt-2.5 flex items-center gap-1 hover:opacity-80",style:{fontSize:"13px",color:t.accent},children:[c?u("modelPage.lessBullets"):x>0?u("modelPage.moreBullets")(x):u("modelPage.showMore"),c?l.jsx(pC,{className:"h-3.5 w-3.5"}):l.jsx(uC,{className:"h-3.5 w-3.5"})]})]}),l.jsx("div",{className:"relative z-10 flex-1",style:{gridRow:3}}),l.jsx("div",{className:"relative z-10",style:{gridRow:4,padding:"20px 20px 28px",background:"linear-gradient(180deg, rgba(8,8,8,0) 0%, rgba(8,8,8,0.85) 45%, rgba(8,8,8,0.95) 100%)"},children:l.jsxs("div",{className:"text-center",children:[!e.price_text&&l.jsx("div",{style:{fontSize:"13px",color:$m},children:u("modelPage.totalPrice")}),l.jsx("div",{style:{marginTop:"4px",fontFamily:"'Barlow Condensed', sans-serif",fontSize:"30px",fontWeight:600,letterSpacing:"1px",color:_E,...e.price_text?g:null},children:e.price_text||i(e.total_price)}),!e.price_text&&a&&l.jsx("div",{style:{marginTop:"2px",fontSize:"11px",color:$m},children:a}),l.jsx(U,{to:o(e),onClick:()=>Yt("select_package",{package_name:e.name,value:Number(e.total_price)||void 0,currency:"EUR"}),className:"mt-4 inline-block rounded-md bg-brand-500 px-4 py-2 text-center text-sm font-semibold text-white shadow-lg shadow-brand-500/30 hover:bg-brand-400",children:u("modelPage.requestContact")}),e.video_url&&l.jsx("div",{className:"mt-3",children:l.jsxs("a",{href:e.video_url,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 rounded-full border border-white/15 bg-white/5 px-3 py-1 text-xs font-semibold text-white transition hover:bg-white/15",children:[l.jsx(yC,{className:"h-4 w-4 text-red-500","aria-hidden":"true"}),u("modelPage.videoLink")]})})]})})]})}function RE(){const{brandSlug:e,modelSlug:t}=$c(),[n,r]=p.useState(null),[s,i]=p.useState(null),o=ma(),{t:a,language:u}=rt(),{package_card_theme:c,package_card_layout:d,package_wheel_hint_interval:f,package_card_width:h,package_card_height:y,phone:x,whatsapp:w,price_note:b,price_note_en:m}=Lt(),g=u==="en"&&m||b,v=Hm[c]||Hm.graphite,k=["grid","strip","coverflow"].includes(d)?d:"strip",S=Math.max(2,Number(f)||8)*1e3,C=p.useRef(null),P=p.useRef(null),j=p.useRef(null),[M,T]=p.useState(!1),O=E=>new Intl.NumberFormat(u==="de"?"de-DE":"en-US",{style:"currency",currency:"EUR"}).format(E);p.useEffect(()=>{o.vehicles.enabled&&!o.bypass||ce.get(`/models/${e}/${t}/packages`).then(r).catch(E=>i(E))},[e,t,o.vehicles.enabled,o.bypass]),p.useEffect(()=>{const E=C.current;if(k!=="coverflow"||!E)return;let A=0;const se=()=>{A=0;const ie=E.scrollLeft+E.clientWidth/2;for(const re of E.children){const De=re.offsetLeft+re.offsetWidth/2,I=Math.max(-1,Math.min(1,(De-ie)/(re.offsetWidth*1.4))),$=Math.abs(I);re.style.transform=`rotateY(${(-I*35).toFixed(2)}deg) scale(${(1-$*.13).toFixed(3)}) translateZ(${(-$*60).toFixed(1)}px)`,re.style.zIndex=String(100-Math.round($*50))}},z=()=>{A||(A=requestAnimationFrame(se))};se(),E.addEventListener("scroll",z,{passive:!0});const de=new ResizeObserver(z);return de.observe(E),()=>{E.removeEventListener("scroll",z),de.disconnect(),cancelAnimationFrame(A)}},[k,n]),p.useEffect(()=>{const E=C.current;if(k==="grid"||!E)return;const A=window.matchMedia("(pointer: coarse)").matches;if(window.matchMedia("(prefers-reduced-motion: reduce)").matches)return;let z=[],de=0;const ie=()=>{const De=Math.min(E.clientWidth*.4,160);z.push(setTimeout(()=>E.scrollTo({left:De,behavior:"smooth"}),500)),z.push(setTimeout(()=>E.scrollTo({left:0,behavior:"smooth"}),1250)),A||(z.push(setTimeout(()=>T(!0),450)),z.push(setTimeout(()=>T(!1),1700)))},re=new IntersectionObserver(([De])=>{De.isIntersecting&&(re.disconnect(),ie(),de=setInterval(()=>{E.scrollLeft<=1&&ie()},S))},{threshold:.35});return re.observe(E),()=>{re.disconnect(),clearInterval(de),z.forEach(clearTimeout)}},[k,n,S]),p.useEffect(()=>{const E=C.current;if(k==="grid"||!E)return;let A=0,se=0,z=!1,de=0,ie=0;const re=()=>[...E.children].map(V=>V.offsetLeft+V.offsetWidth/2),De=(V,oe)=>{let Se=0,te=1/0;return V.forEach((we,dt)=>{const Ln=Math.abs(we-oe);Ln{z=!1;const V=re();if(!V.length)return;const oe=E.scrollLeft+E.clientWidth/2,Se=De(V,oe);let te=Se;Se===de&&Math.abs(ie)>4&&(te=ie>0?Math.min(de+1,V.length-1):Math.max(de-1,0));const we=E.scrollWidth-E.clientWidth,dt=Math.max(0,Math.min(V[te]-E.clientWidth/2,we));E.scrollTo({left:dt,behavior:"smooth"}),clearTimeout(se),se=setTimeout(()=>{E.style.scrollSnapType=""},450)},$=V=>{if(Math.abs(V.deltaX)>Math.abs(V.deltaY))return;const oe=E.scrollWidth-E.clientWidth;if(oe<=1)return;const Se=E.scrollLeft<=1,te=E.scrollLeft>=oe-1;V.deltaY<0&&Se||V.deltaY>0&&te||(V.preventDefault(),z||(z=!0,ie=0,de=De(re(),E.scrollLeft+E.clientWidth/2)),ie+=V.deltaY,E.style.scrollSnapType="none",E.scrollLeft+=V.deltaY,clearTimeout(A),A=setTimeout(I,150))};return E.addEventListener("wheel",$,{passive:!1}),()=>{E.removeEventListener("wheel",$),clearTimeout(A),clearTimeout(se)}},[k,n]),p.useEffect(()=>{const E=C.current,A=P.current,se=j.current;if(k==="grid"||!E||!A||!se)return;let z=0;const de=()=>{z=0;const te=E.scrollWidth-E.clientWidth;if(te<=1){A.style.opacity="0",A.style.pointerEvents="none";return}A.style.opacity="1",A.style.pointerEvents="auto";const we=A.clientWidth,dt=Math.max(32,E.clientWidth/E.scrollWidth*we);se.style.width=`${dt}px`,se.style.transform=`translateX(${(E.scrollLeft/te*(we-dt)).toFixed(1)}px)`},ie=()=>{z||(z=requestAnimationFrame(de))};de(),E.addEventListener("scroll",ie,{passive:!0});const re=new ResizeObserver(ie);re.observe(E);let De=!1,I=0;const $=te=>{const we=A.getBoundingClientRect(),dt=se.clientWidth,Ln=Math.min(Math.max(te-we.left-I,0),we.width-dt);E.scrollLeft=Ln/(we.width-dt)*(E.scrollWidth-E.clientWidth)},V=te=>{De=!0,A.setPointerCapture(te.pointerId),E.style.scrollSnapType="none";const we=se.getBoundingClientRect();I=te.clientX>=we.left&&te.clientX<=we.right?te.clientX-we.left:se.clientWidth/2,te.clientX>=we.left&&te.clientX<=we.right||$(te.clientX)},oe=te=>{De&&$(te.clientX)},Se=te=>{var we;De&&(De=!1,(we=A.hasPointerCapture)!=null&&we.call(A,te.pointerId)&&A.releasePointerCapture(te.pointerId),E.style.scrollSnapType="")};return A.addEventListener("pointerdown",V),A.addEventListener("pointermove",oe),A.addEventListener("pointerup",Se),A.addEventListener("pointercancel",Se),()=>{E.removeEventListener("scroll",ie),re.disconnect(),cancelAnimationFrame(z),A.removeEventListener("pointerdown",V),A.removeEventListener("pointermove",oe),A.removeEventListener("pointerup",Se),A.removeEventListener("pointercancel",Se)}},[k,n]),rr({title:n?a("modelPage.metaTitle")(n.model.brand_name,n.model.name):a("modelPage.metaTitleFallback"),description:n?a("modelPage.metaDescription")(n.model.brand_name,n.model.name):void 0,path:`/fahrzeuge/${e}/${t}`});const G=Be(n?`car_models.${n.model.id}.name`:"");if(o.vehicles.enabled&&!o.bypass)return l.jsx(ai,{message:o.vehicles.message});if(s)return s.status===404?l.jsx(Nd,{}):l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-red-600 sm:px-6",children:ga(s,a)});if(!n)return l.jsx("p",{className:"mx-auto max-w-6xl px-4 py-12 text-neutral-500 sm:px-6",children:a("modelPage.loading")});const{model:W}=n,H=n.packages.map(E=>({...E,description:jn(E,"description",u),tagline:jn(E,"tagline",u),price_text:jn(E,"price_text",u)})),Y=new Map([...H].sort((E,A)=>E.total_price-A.total_price).map((E,A)=>[E.id,A])),q=E=>{const A=E.tier_count??H.length,se=E.tier_rank??Y.get(E.id)??0,z=A<=1?0:se/(A-1),de=Math.round(z*(v.length-1));return{tier:v[de],tierT:z}},le=E=>[...E.products.map(A=>({text:A.name_override||A.scraped_name||a("modelPage.productLoading"),fromDescription:!1})),...(E.description||"").split(` -`).map(A=>A.trim()).filter(Boolean).map(A=>({text:A,fromDescription:!0}))],N=E=>`/kontakt?${new URLSearchParams({brand:W.brand_name,model:W.name,package:E.name,packageId:E.id,total:E.total_price,brandSlug:e,modelSlug:t}).toString()}`,L=`/kontakt?${new URLSearchParams({brand:W.brand_name,model:W.name}).toString()}`,F=a("modelPage.whatsappText")(W.brand_name,W.name);return l.jsxs(l.Fragment,{children:[l.jsxs("div",{className:"mx-auto max-w-6xl px-4 pt-12 sm:px-6",children:[o.vehicles.enabled&&o.bypass&&l.jsx(li,{inline:!0}),l.jsxs("p",{className:"mb-1 text-sm text-neutral-500 dark:text-neutral-400",children:[l.jsx(U,{to:"/fahrzeuge",className:"hover:text-brand-500",children:a("modelPage.breadcrumbVehicles")})," /"," ",l.jsx(U,{to:`/fahrzeuge/${e}`,className:"hover:text-brand-500",children:W.brand_name})," / ",l.jsx("span",{style:G,children:W.name})]}),l.jsxs("h1",{className:`text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl ${H.length?"mb-2":"mb-8"}`,children:[W.brand_name," ",l.jsx("span",{style:G,children:W.name})," – ",a("modelPage.titleSuffix")]}),H.length===0&&l.jsxs("div",{className:"pb-12",children:[l.jsx("p",{className:"text-neutral-500 dark:text-neutral-400",children:a("modelPage.empty")}),l.jsx(U,{to:L,className:"mt-5 inline-block rounded-md bg-brand-500 px-5 py-3 text-sm font-semibold text-white shadow-sm hover:bg-brand-600",children:a("modelPage.customRequest")})]})]}),H.length>0&&l.jsx("section",{className:"py-10 sm:py-14",style:{fontFamily:"'Barlow', sans-serif"},children:l.jsxs("div",{className:k==="grid"?"mx-auto max-w-6xl px-4 sm:px-6":"relative mx-auto max-w-[1880px] px-4 sm:px-6",children:[l.jsx("div",{ref:k==="grid"?void 0:C,className:k==="grid"?"grid items-stretch gap-[18px]":"grid select-none gap-x-[18px] overflow-x-auto pb-3 snap-x snap-mandatory [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",style:k==="grid"?{gridTemplateColumns:`repeat(auto-fill, minmax(${h}px, 1fr))`,gridAutoRows:"1fr"}:{gridAutoFlow:"column",gridAutoColumns:`${h}px`,gridTemplateRows:"auto auto 1fr auto",minHeight:`${Number(y)+(k==="coverflow"?22:12)}px`,...k==="coverflow"?{perspective:"1200px",paddingLeft:`calc(50% - ${h/2}px)`,paddingRight:`calc(50% - ${h/2}px)`,paddingTop:"10px"}:null},children:H.map(E=>{const{tier:A,tierT:se}=q(E);return l.jsx(DE,{pkg:E,tier:A,tierT:se,layout:k,bullets:le(E),formatPrice:O,contactUrl:N,priceNote:g,t:a},E.id)})}),k!=="grid"&&l.jsx("div",{className:`pointer-events-none absolute inset-x-0 top-1/2 z-[200] flex -translate-y-1/2 justify-center transition-opacity duration-300 ${M?"opacity-100":"opacity-0"}`,"aria-hidden":"true",children:l.jsxs("div",{className:"flex items-center gap-2 rounded-full border border-white/10 bg-neutral-900/85 px-4 py-2 text-xs font-medium text-white shadow-lg backdrop-blur-sm",children:[l.jsx(dC,{className:"h-3.5 w-3.5 text-brand-400"}),l.jsx(RC,{className:"h-4 w-4 text-brand-400"}),l.jsx(hC,{className:"h-3.5 w-3.5 text-brand-400"}),l.jsx("span",{children:a("modelPage.wheelHint")})]})}),k!=="grid"&&l.jsx("div",{ref:P,className:"relative mx-auto mt-5 h-2 w-56 max-w-full cursor-pointer rounded-full bg-neutral-900/10 transition-opacity duration-200 dark:bg-white/10",style:{touchAction:"none"},"aria-hidden":"true",children:l.jsx("div",{ref:j,className:"absolute left-0 top-0 h-full rounded-full bg-brand-500 shadow-[0_0_10px_rgba(107,166,38,0.7)]",style:{width:"48px"}})})]})}),H.length>0&&l.jsxs("div",{className:"mx-auto max-w-6xl px-4 pb-24 text-center sm:px-6 sm:pb-14",children:[l.jsx("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:a("modelPage.customHint")}),l.jsx(U,{to:L,className:"mt-2 inline-block text-sm font-semibold text-brand-600 underline hover:text-brand-500",children:a("modelPage.customRequest")})]}),(x||w)&&l.jsxs("div",{className:"fixed inset-x-0 bottom-0 z-20 flex gap-3 border-t border-neutral-200 bg-white/95 px-4 py-3 shadow-[0_-8px_24px_rgba(0,0,0,0.08)] backdrop-blur dark:border-neutral-800 dark:bg-neutral-950/95 sm:hidden",children:[x&&l.jsxs("a",{href:Bo(x),onClick:()=>Yt("contact_call"),className:"flex flex-1 items-center justify-center gap-2 rounded-md bg-brand-500 px-4 py-2.5 text-sm font-semibold text-white",children:[l.jsx(Jn,{className:"h-4 w-4"}),a("nav.call")]}),w&&l.jsxs("a",{href:Pd(w,F),target:"_blank",rel:"noopener noreferrer",onClick:()=>Yt("contact_whatsapp"),className:"flex flex-1 items-center justify-center gap-2 rounded-md border border-neutral-300 px-4 py-2.5 text-sm font-semibold text-neutral-700 dark:border-neutral-700 dark:text-neutral-200",children:[l.jsx(fx,{className:"h-4 w-4"}),a("nav.whatsapp")]})]})]})}const IE={car:zo,caravan:iC,"car-front":nC,cog:wC,zap:eT,boxes:eC,"shield-alert":UC,video:QC},VE=p.lazy(()=>X(()=>import("./iconRegistry-CE8benTi.js"),__vite__mapDeps([0,1,2,3,4])));function FE({name:e,className:t="h-6 w-6",...n}){if(!e)return null;const r=IE[e];return r?l.jsx(r,{className:t,...n}):l.jsx(p.Suspense,{fallback:l.jsx("span",{className:`inline-block ${t}`,"aria-hidden":"true"}),children:l.jsx(VE,{name:e,className:t,...n})})}function OE(){const[e,t]=p.useState([]),n=ma(),{t:r,language:s}=rt();return p.useEffect(()=>{ce.get("/services").then(t).catch(()=>t([]))},[]),rr({title:r("leistungen.metaTitle"),description:r("leistungen.metaDescription"),path:"/leistungen"}),n.services.enabled&&!n.bypass?l.jsx(ai,{message:n.services.message}):l.jsxs("div",{className:"mx-auto max-w-6xl px-4 py-12 sm:px-6",children:[n.services.enabled&&n.bypass&&l.jsx(li,{inline:!0}),l.jsx("h1",{className:"mb-2 text-2xl font-bold text-neutral-900 dark:text-white sm:text-3xl",children:r("leistungen.title")}),l.jsx("p",{className:"mb-10 max-w-2xl text-neutral-600 dark:text-neutral-300",children:r("leistungen.intro")}),l.jsx("div",{className:"grid gap-5 sm:grid-cols-2 lg:grid-cols-3",children:e.map(i=>({...i,title:jn(i,"title",s),description:jn(i,"description",s),cta_label:jn(i,"cta_label",s)})).map((i,o)=>l.jsxs(ze,{index:o%3,shine:!0,className:"overflow-hidden rounded-xl border border-neutral-200 bg-white dark:border-neutral-800 dark:bg-neutral-900",children:[l.jsxs("div",{className:"relative aspect-[4/3]",children:[i.image_path&&l.jsx("img",{src:i.image_path,alt:i.title,className:"h-full w-full object-cover",loading:"lazy"}),l.jsx("div",{className:"absolute -bottom-5 left-5 flex h-12 w-12 items-center justify-center rounded-full bg-brand-500 text-white shadow-lg ring-4 ring-white dark:ring-neutral-900",children:l.jsx(FE,{name:i.icon_name,className:"h-6 w-6"})})]}),l.jsxs("div",{className:"p-6 pt-8",children:[l.jsx("h2",{className:"mb-2 font-semibold text-neutral-900 dark:text-white",children:i.title}),l.jsx("p",{className:"mb-3 text-sm text-neutral-600 dark:text-neutral-300",children:i.description}),l.jsxs(U,{to:i.cta_url||"/kontakt",className:"text-sm font-semibold text-brand-600 hover:underline dark:text-brand-400",children:[i.cta_label||r("leistungen.contact")," →"]})]})]},i.id))}),l.jsxs("div",{className:"mt-12 rounded-xl border border-neutral-200 bg-neutral-50 p-8 text-center dark:border-neutral-800 dark:bg-neutral-900/40",children:[l.jsx("h2",{className:"mb-2 text-xl font-bold text-neutral-900 dark:text-white",children:r("leistungen.notListedTitle")}),l.jsx("p",{className:"mb-5 text-neutral-600 dark:text-neutral-300",children:r("leistungen.notListedText")}),l.jsx(U,{to:"/kontakt",className:"inline-block rounded-md bg-brand-500 px-6 py-3 text-sm font-semibold text-white hover:bg-brand-600",children:r("leistungen.contact")})]})]})}function zE({name:e,description:t,className:n="",children:r}){const{consent:s,acceptAll:i,openSettings:o}=Yr();return s.external?r:l.jsxs("div",{className:`flex flex-col items-center justify-center gap-3 rounded-xl border border-neutral-200 bg-neutral-50 p-6 text-center dark:border-neutral-800 dark:bg-neutral-900/40 ${n}`,children:[l.jsx("p",{className:"text-sm text-neutral-600 dark:text-neutral-300",children:t||`${e} wird erst nach deiner Zustimmung geladen, da dabei Daten an Google übertragen werden.`}),l.jsxs("div",{className:"flex flex-wrap justify-center gap-2",children:[l.jsx("button",{type:"button",onClick:i,className:"rounded-md bg-brand-500 px-4 py-2 text-sm font-semibold text-white hover:bg-brand-600",children:"Laden erlauben"}),l.jsx("button",{type:"button",onClick:o,className:"rounded-md border border-neutral-300 px-4 py-2 text-sm dark:border-neutral-700",children:"Cookie-Einstellungen"})]})]})}const BE=e=>(e||"").replace(/[^\d+]/g,""),to={fontFamily:"'Michroma', sans-serif"};function HE({className:e}){return l.jsx("svg",{className:e,viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:l.jsx("path",{d:"M12 2a10 10 0 0 0-8.6 15l-1.3 4.8 5-1.3A10 10 0 1 0 12 2zm0 2a8 8 0 1 1-4.2 14.8l-.3-.2-2.6.7.7-2.5-.2-.3A8 8 0 0 1 12 4zm4.3 9.9c-.2-.1-1.4-.7-1.6-.8s-.4-.1-.5.1l-.7.9c-.1.1-.3.2-.5.1a6.5 6.5 0 0 1-3.2-2.8c-.1-.2 0-.4.1-.5l.4-.5.2-.4v-.4l-.7-1.7c-.2-.4-.4-.4-.5-.4h-.5c-.2 0-.4.1-.6.3-.7.7-.9 1.6-.6 2.7.5 1.7 1.6 3.1 3.4 4.2 1.7 1 2.5 1 3.4.9.5-.1 1.4-.6 1.6-1.1.2-.5.2-1 .1-1.1z"})})}function $E({path:e,className:t}){return l.jsx("svg",{className:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:l.jsx("path",{d:e})})}const UE={premium:"M4 12v3M8 8v11M12 4v16M16 8v11M20 12v3",germany:"M12 12m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0 M12 2v2M12 20v2M2 12h2M20 12h2M5 5l1.5 1.5M17.5 17.5 19 19M19 5l-1.5 1.5M6.5 17.5 5 19",individual:"M6 3h12l4 6-10 12L2 9z M11 3 8 9l4 12 4-12-3-6M2 9h20",experts:"M20 6 9 17l-5-5"};function Wm({formatted:e,color:t}){const[n,r]=e.split("€");return l.jsxs("span",{style:{...to,color:t},children:[n,l.jsx("span",{style:{fontFamily:"'Barlow', sans-serif"},children:"€"}),r]})}function Ai({icon:e,label:t,name:n,type:r="text",required:s,value:i,onChange:o,placeholder:a,autoComplete:u,inputMode:c}){return l.jsxs("div",{className:"flex flex-col gap-2",children:[l.jsx("label",{htmlFor:`kf-${n}`,className:"text-xs font-semibold uppercase tracking-[2px]",style:{color:"var(--kf-label)"},children:t}),l.jsxs("div",{className:"relative flex items-center",children:[l.jsx(e,{className:"pointer-events-none absolute left-[14px] h-[17px] w-[17px]",style:{color:"var(--kf-fieldicon)"}}),l.jsx("input",{id:`kf-${n}`,name:n,type:r,required:s,autoComplete:u,inputMode:c,value:i,onChange:o,placeholder:a,className:"w-full rounded-lg border py-3.5 pl-[42px] pr-4 text-[15px] outline-none transition-colors",style:{background:"var(--kf-field)",borderColor:"var(--kf-fieldbrd)",color:"var(--kf-text2)"}})]})]})}function WE(){const[e]=dk(),{phone:t,whatsapp:n,contact_email:r,address_street:s,address_zip:i,address_city:o,business_hours:a,price_note:u,price_note_en:c}=Lt(),{t:d,language:f}=rt(),{consent:h}=Yr(),y=[s,[i,o].filter(Boolean).join(" ")].filter(Boolean).join(", "),x=encodeURIComponent(y),w=`https://www.google.com/maps/dir/?api=1&destination=${x}`,b=wx(a,d("footer.closed")),m=V=>new Intl.NumberFormat(f==="de"?"de-DE":"en-US",{style:"currency",currency:"EUR"}).format(V),[g,v]=p.useState(()=>({name:"",email:"",phone:"",vin:"",message:e.get("topic")||""})),[k,S]=p.useState("idle"),[C,P]=p.useState(""),[j,M]=p.useState([]),[T,O]=p.useState([]),G=p.useRef(Date.now()),W=p.useRef(null),H=e.get("packageId"),Y=e.get("brandSlug"),q=e.get("modelSlug"),[le,N]=p.useState(e.get("total")?Number(e.get("total")):null),[L,F]=p.useState(null),E=f==="en"&&c||u;p.useEffect(()=>{!H||!Y||!q||ce.get(`/models/${encodeURIComponent(Y)}/${encodeURIComponent(q)}/packages`).then(V=>{var Se;const oe=(Se=V==null?void 0:V.packages)==null?void 0:Se.find(te=>String(te.id)===String(H));oe&&(N(Number(oe.total_price)),F(oe.price_text||null))}).catch(()=>{})},[H,Y,q]),p.useEffect(()=>{if(!H){M([]);return}ce.get(`/packages/${H}/upgrades`).then(M).catch(()=>M([]))},[H]);const A=V=>{O(oe=>oe.includes(V)?oe.filter(Se=>Se!==V):[...oe,V])},se=j.filter(V=>T.includes(V.id)).reduce((V,oe)=>V+Number(oe.price),0);rr({title:d("contactPage.metaTitle"),description:d("contactPage.metaDescription"),path:"/kontakt"});const z={brand:e.get("brand")||"",model:e.get("model")||"",package:e.get("package")||""},de=!!(z.brand&&z.model&&z.package),ie=!de&&!!(z.brand&&z.model),re=V=>v(oe=>({...oe,[V.target.name]:V.target.value})),De=async V=>{var oe;V.preventDefault(),S("sending"),P("");try{await ce.post("/contact",{...g,website:((oe=V.target.elements.website)==null?void 0:oe.value)||"",fill_ms:Date.now()-G.current,brand_name:z.brand||null,model_name:z.model||null,package_name:z.package||null,product_name:e.get("product")||null,package_id:H||null,package_product_id:e.get("productId")||null,upgrade_ids:T}),S("sent"),v({name:"",email:"",phone:"",vin:"",message:""}),Yt("generate_lead",{package_name:z.package||void 0,value:le||void 0,currency:"EUR"})}catch(Se){P(ga(Se,d)),S("idle")}};p.useEffect(()=>{k==="sent"&&W.current&&(W.current.scrollIntoView({behavior:"smooth",block:"center"}),W.current.focus({preventScroll:!0}))},[k]);const I=de?d("contactPage.whatsappText")(z.brand,z.model,z.package):ie?d("modelPage.whatsappText")(z.brand,z.model):"",$=[{key:"premium",title:d("contactPage.featurePremiumTitle"),sub:d("contactPage.featurePremiumSub")},{key:"germany",title:d("contactPage.featureGermanyTitle"),sub:d("contactPage.featureGermanySub")},{key:"individual",title:d("contactPage.featureIndividualTitle"),sub:d("contactPage.featureIndividualSub")},{key:"experts",title:d("contactPage.featureExpertsTitle"),sub:d("contactPage.featureExpertsSub")}];return l.jsx("div",{className:"kf-page kontakt-sektion relative w-full overflow-hidden px-4 pb-10 sm:px-10",style:{color:"var(--kf-text2)",fontFamily:"'Barlow', sans-serif"},children:l.jsxs("div",{className:"relative z-10 mx-auto max-w-[1280px] pt-10 sm:pt-14",children:[l.jsx("div",{className:"mb-3 text-[13px] font-semibold uppercase tracking-[6px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.heroEyebrow")}),l.jsxs("h1",{className:"text-[34px] leading-[1.08] sm:text-[46px] lg:text-[60px]",style:{...to,color:"var(--kf-text)"},children:[d("contactPage.heroTitlePre")," ",l.jsx("span",{style:{color:"var(--kf-accent2)"},children:d("contactPage.heroTitleAccent")})," ",d("contactPage.heroTitlePost")]}),l.jsx("p",{className:"mb-10 mt-5 max-w-[520px] text-lg leading-[1.55]",style:{color:"var(--kf-muted)"},children:d("contactPage.heroSubtitle")}),l.jsxs("div",{className:"grid grid-cols-1 items-start gap-10 min-[981px]:grid-cols-[minmax(0,1.35fr)_minmax(320px,1fr)]",children:[l.jsx("div",{children:l.jsxs("div",{className:"rounded-2xl border p-[22px] sm:p-10",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow)"},children:[de&&l.jsxs("div",{className:"mb-8 rounded-xl border px-6 py-[22px]",style:{background:"var(--kf-pkgbg)",borderColor:"var(--kf-pkgbrd)"},children:[l.jsxs("div",{className:"mb-3.5 flex items-center gap-2.5 text-xs font-bold uppercase tracking-[2px]",style:{color:"var(--kf-accent2)"},children:[l.jsx(OC,{className:"h-4 w-4"}),d("contactPage.packageBoxTitle")]}),l.jsxs("div",{className:"grid grid-cols-[auto_1fr] gap-x-5 gap-y-2 text-[15px]",children:[l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.contextBrand")}),l.jsx("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:z.brand}),l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.contextModel")}),l.jsx("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:z.model}),l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.contextPackage")}),l.jsx("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:z.package})]}),l.jsxs("div",{className:"mt-3.5 flex items-baseline justify-between border-t pt-3.5",style:{borderColor:"var(--kf-pkgbrd)"},children:[l.jsx("span",{className:"text-[13px] font-semibold uppercase tracking-wide",style:{color:"var(--kf-muted)"},children:d("contactPage.packagePrice")}),l.jsx("span",{className:"text-xl",children:L||(le!=null?l.jsx(Wm,{formatted:m(le),color:"var(--kf-text)"}):"—")})]}),E&&!L&&l.jsx("div",{className:"mt-1 text-right text-xs",style:{color:"var(--kf-muted)"},children:E})]}),ie&&l.jsxs("div",{className:"mb-8 flex items-center gap-3 rounded-xl border px-6 py-4 text-[15px]",style:{background:"var(--kf-pkgbg)",borderColor:"var(--kf-pkgbrd)"},children:[l.jsx(zo,{className:"h-4 w-4",style:{color:"var(--kf-accent2)"}}),l.jsx("span",{style:{color:"var(--kf-label)"},children:d("contactPage.vehicleBoxTitle")}),l.jsxs("span",{className:"font-semibold",style:{color:"var(--kf-text2)"},children:[z.brand," ",z.model]})]}),j.length>0&&l.jsxs("div",{className:"mb-8 rounded-xl border p-5",style:{background:"var(--kf-field)",borderColor:"var(--kf-fieldbrd)"},children:[l.jsx("div",{className:"mb-3 text-xs font-bold uppercase tracking-[2px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.optionalUpgrades")}),l.jsx("div",{className:"space-y-2",children:j.map(V=>l.jsxs("label",{className:"flex cursor-pointer items-start gap-3 rounded-lg border p-3 text-sm",style:{borderColor:"var(--kf-fieldbrd)"},children:[l.jsx("input",{type:"checkbox",checked:T.includes(V.id),onChange:()=>A(V.id),className:"mt-0.5 h-4 w-4 rounded",style:{accentColor:"var(--kf-accent)"}}),l.jsxs("span",{className:"flex-1",children:[l.jsx("span",{className:"block font-semibold",style:{color:"var(--kf-text2)"},children:jn(V,"name",f)}),V.description&&l.jsx("span",{className:"block text-xs",style:{color:"var(--kf-muted)"},children:jn(V,"description",f)})]}),l.jsxs("span",{className:"font-semibold",style:{color:"var(--kf-accent2)"},children:["+",m(V.price)]})]},V.id))}),T.length>0&&le!=null&&!L&&l.jsxs("div",{className:"mt-3 flex items-baseline justify-between border-t pt-3 text-sm",style:{borderColor:"var(--kf-pkgbrd)"},children:[l.jsx("span",{className:"text-xs font-semibold uppercase tracking-wide",style:{color:"var(--kf-muted)"},children:d("contactPage.totalWithUpgrades")}),l.jsx(Wm,{formatted:m(le+se),color:"var(--kf-text)"})]})]}),l.jsx("h2",{className:"mb-8 text-xl",style:{...to,color:"var(--kf-text)"},children:d("contactPage.formTitle")}),l.jsx("div",{role:"status","aria-live":"polite",children:k==="sent"&&l.jsxs("div",{ref:W,tabIndex:-1,className:"rounded-[10px] border p-5 outline-none",style:{borderColor:"var(--kf-accent)",background:"var(--kf-accentsoft)"},children:[l.jsx("div",{className:"text-base font-bold",style:{color:"var(--kf-accent2)"},children:d("contactPage.sentTitle")}),l.jsx("div",{className:"mt-1 text-sm",style:{color:"var(--kf-muted)"},children:d("contactPage.sentText")}),l.jsx("button",{type:"button",onClick:()=>{G.current=Date.now(),S("idle")},className:"mt-4 text-sm font-semibold underline",style:{color:"var(--kf-text2)"},children:d("contactPage.sendAnother")})]})}),k!=="sent"&&l.jsxs("form",{onSubmit:De,noValidate:!1,children:[l.jsxs("div",{"aria-hidden":"true",style:{position:"absolute",left:"-10000px",width:"1px",height:"1px",overflow:"hidden"},children:[l.jsx("label",{htmlFor:"kf-website",children:"Website"}),l.jsx("input",{id:"kf-website",name:"website",type:"text",tabIndex:-1,autoComplete:"off",defaultValue:""})]}),l.jsxs("div",{className:"grid grid-cols-1 gap-6 min-[641px]:grid-cols-2",children:[l.jsx(Ai,{icon:XC,label:d("contactPage.nameLabel"),name:"name",autoComplete:"name",required:!0,value:g.name,onChange:re,placeholder:d("contactPage.namePlaceholder")}),l.jsx(Ai,{icon:Hu,label:d("contactPage.emailLabel"),name:"email",type:"email",autoComplete:"email",required:!0,value:g.email,onChange:re,placeholder:d("contactPage.emailPlaceholder")}),l.jsx(Ai,{icon:Jn,label:d("contactPage.phoneLabel"),name:"phone",type:"tel",inputMode:"tel",autoComplete:"tel",value:g.phone,onChange:re,placeholder:d("contactPage.phonePlaceholder")}),l.jsx(Ai,{icon:zo,label:d("contactPage.vinLabel"),name:"vin",value:g.vin,onChange:re,placeholder:d("contactPage.vinPlaceholder")})]}),l.jsxs("div",{className:"mt-6 flex flex-col gap-2",children:[l.jsx("label",{htmlFor:"kf-message",className:"text-xs font-semibold uppercase tracking-[2px]",style:{color:"var(--kf-label)"},children:d("contactPage.messageLabel")}),l.jsx("textarea",{id:"kf-message",name:"message",rows:5,value:g.message,onChange:re,placeholder:d("contactPage.messagePlaceholder"),className:"w-full resize-y rounded-lg border px-4 py-3.5 text-[15px] outline-none",style:{background:"var(--kf-field)",borderColor:"var(--kf-fieldbrd)",color:"var(--kf-text2)"}})]}),l.jsx("div",{role:"alert","aria-live":"assertive",children:C&&l.jsx("p",{className:"mt-4 text-sm text-red-600 dark:text-red-400",children:C})}),l.jsxs("div",{className:"mt-8 flex flex-wrap items-center gap-5",children:[l.jsxs("button",{type:"submit",disabled:k==="sending",className:"inline-flex items-center gap-3 rounded-lg px-8 py-4 text-sm font-bold uppercase tracking-[3px] transition-[filter,box-shadow] hover:brightness-110 disabled:opacity-60",style:{background:"var(--kf-accent)",color:"var(--kf-btntext)",boxShadow:"0 10px 24px rgba(150,200,20,0.32)"},children:[l.jsx(HC,{className:"h-[18px] w-[18px]"}),d(k==="sending"?"contactPage.sending":"contactPage.submit")]}),l.jsx("div",{className:"text-[13px]",style:{color:"var(--kf-label)"},children:d("contactPage.requiredHint")})]}),l.jsxs("p",{className:"mt-5 text-[13px] leading-relaxed",style:{color:"var(--kf-muted)"},children:[d("contactPage.privacyPre"),l.jsx(U,{to:"/datenschutz",className:"underline",style:{color:"var(--kf-text2)"},children:d("contactPage.privacyLink")}),d("contactPage.privacyPost")]})]})]})}),l.jsxs("div",{className:"flex flex-col gap-6",children:[l.jsxs("div",{className:"relative overflow-hidden rounded-2xl border px-[22px] py-[26px] sm:px-8 sm:py-[34px]",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow)"},children:[l.jsx("div",{className:"pointer-events-none absolute -right-[60px] -top-[60px] h-[190px] w-[190px] rounded-full border border-dashed",style:{borderColor:"var(--kf-pkgbrd)"}}),l.jsx("h2",{className:"mb-7 text-[17px]",style:{...to,color:"var(--kf-text)"},children:d("contactPage.cardTitle")}),l.jsxs("div",{className:"flex flex-col gap-5",children:[l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(Jn,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.phone")}),l.jsx("a",{href:`tel:${BE(t)}`,onClick:()=>Yt("contact_call"),className:"text-base font-semibold",style:{color:"var(--kf-text2)"},children:t})]})]}),l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(Hu,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.email")}),l.jsx("a",{href:`mailto:${r}`,className:"text-base font-semibold",style:{color:"var(--kf-text2)"},children:r})]})]}),l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(dx,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.address")}),l.jsxs("div",{className:"text-base font-semibold leading-[1.4]",style:{color:"var(--kf-text2)"},children:[s,l.jsx("br",{}),[i,o].filter(Boolean).join(" ")]})]})]}),n&&l.jsxs("div",{className:"flex items-start gap-4",children:[l.jsx("div",{className:"flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full",style:{background:"var(--kf-accentsoft)"},children:l.jsx(HE,{className:"h-[18px] w-[18px]",style:{color:"var(--kf-accent2)"}})}),l.jsxs("div",{children:[l.jsx("div",{className:"mb-1 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("nav.whatsapp")}),l.jsx("a",{href:Pd(n,I),target:"_blank",rel:"noopener noreferrer",onClick:()=>Yt("contact_whatsapp"),className:"text-base font-semibold",style:{color:"var(--kf-text2)"},children:n})]})]})]}),l.jsxs("div",{className:"mt-7 border-t pt-6",style:{borderColor:"var(--kf-divider)"},children:[l.jsx("div",{className:"mb-3 text-[11px] font-semibold uppercase tracking-[3px]",style:{color:"var(--kf-accent2)"},children:d("contactPage.hours")}),l.jsx("div",{className:"grid grid-cols-[auto_1fr] gap-x-6 gap-y-2 text-[15px]",children:b.map(V=>l.jsxs("span",{style:{display:"contents"},children:[l.jsx("span",{style:{color:"var(--kf-label)"},children:V.days}),l.jsx("span",{children:V.label})]},V.key))})]})]}),l.jsxs("div",{className:"relative overflow-hidden rounded-2xl border",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow)"},children:[h.external&&l.jsxs("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"absolute left-3.5 top-3.5 z-10 inline-flex items-center gap-2 rounded-lg border px-3.5 py-2 text-[13px] font-semibold hover:border-[var(--kf-accent)]",style:{background:"var(--kf-pill)",borderColor:"var(--kf-pillbrd)",color:"var(--kf-text2)",boxShadow:"var(--kf-shadow2)"},children:[d("contactPage.mapOpenChip"),l.jsx(bC,{className:"h-3.5 w-3.5",style:{color:"var(--kf-accent2)"}})]}),l.jsx(zE,{name:d("contactPage.mapEmbedName"),className:"h-[210px] w-full",children:l.jsx("div",{className:"h-[210px] overflow-hidden",children:l.jsx("iframe",{title:d("contactPage.mapIframeTitle"),src:`https://www.google.com/maps?q=${x}&output=embed`,width:"100%",height:"290",style:{border:0,display:"block",marginTop:"-60px"},loading:"lazy",referrerPolicy:"no-referrer-when-downgrade"})})}),l.jsxs("a",{href:w,target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2.5 border-t px-4 py-4 text-[13px] font-bold uppercase tracking-[3px] hover:bg-[var(--kf-accentsoft)]",style:{borderColor:"var(--kf-divider)",color:"var(--kf-accent2)"},children:[d("contactPage.routePlan")," →"]})]})]})]}),l.jsx("div",{className:"mt-10 grid grid-cols-1 overflow-hidden rounded-2xl border min-[641px]:grid-cols-2 min-[901px]:grid-cols-4",style:{background:"var(--kf-card)",borderColor:"var(--kf-cardbrd)",boxShadow:"var(--kf-shadow2)"},children:$.map(V=>l.jsxs("div",{className:"flex items-center gap-4 border-b p-6 last:border-b-0 min-[641px]:border-b-0 min-[641px]:border-r min-[641px]:last:border-r-0",style:{borderColor:"var(--kf-divider)"},children:[l.jsx("div",{className:"flex h-[46px] w-[46px] flex-shrink-0 items-center justify-center rounded-full border-[1.5px]",style:{borderColor:"var(--kf-pkgbrd)",color:"var(--kf-accent2)"},children:l.jsx($E,{path:UE[V.key],className:"h-[22px] w-[22px]"})}),l.jsxs("div",{children:[l.jsx("div",{className:"text-[15px] font-bold",style:{color:"var(--kf-text)"},children:V.title}),l.jsx("div",{className:"mt-0.5 text-[13px]",style:{color:"var(--kf-muted)"},children:V.sub})]})]},V.key))})]})})}const hl="hifi-chunk-reload",Q=e=>p.lazy(()=>e().then(t=>{try{sessionStorage.removeItem(hl)}catch{}return t},t=>{let n=!0;try{n=!!sessionStorage.getItem(hl),sessionStorage.setItem(hl,"1")}catch{}if(n)throw t;return window.location.reload(),new Promise(()=>{})})),GE=Q(()=>X(()=>import("./GalleryOverview-0HIJlhh1.js"),[])),KE=Q(()=>X(()=>import("./GalleryBrandPage-C8027MHD.js"),[])),qE=Q(()=>X(()=>import("./GalleryProjectPage-BLlGc26k.js"),[])),YE=Q(()=>X(()=>import("./DownloadsPage-BIItFx8g.js"),__vite__mapDeps([5,6,1]))),XE=Q(()=>X(()=>import("./Impressum-CFvSH0LV.js"),[])),ZE=Q(()=>X(()=>import("./Datenschutz-BkjVpsNF.js"),[])),QE=Q(()=>X(()=>import("./AGB-D307xiNj.js"),[])),JE=Q(()=>X(()=>import("./SetupWizard-DYZvf-vp.js"),[])),eN=Q(()=>X(()=>import("./Login-CRdfT-83.js"),[])),tN=Q(()=>X(()=>import("./Dashboard-DNZlgdsq.js"),__vite__mapDeps([7,8,9]))),nN=Q(()=>X(()=>import("./Brands-DKoTUwWY.js"),__vite__mapDeps([10,11,12,13,14,15,3]))),rN=Q(()=>X(()=>import("./Models-D3NVlJTw.js"),__vite__mapDeps([16,11,12,13,14,15,3,17]))),sN=Q(()=>X(()=>import("./GalleryBrands-B2uVgrZq.js"),__vite__mapDeps([18,11,12,14,15,3,17]))),iN=Q(()=>X(()=>import("./GalleryProjects-D3Z0gSrh.js"),__vite__mapDeps([19,11,12,14,15,3,17]))),oN=Q(()=>X(()=>import("./GalleryPhotos-_0TxVvt5.js"),__vite__mapDeps([20,14,15,3,17,12]))),aN=Q(()=>X(()=>import("./Packages-CJRPrtXw.js"),__vite__mapDeps([21,13,17,15,4,3,2]))),lN=Q(()=>X(()=>import("./Services-CAauKrT-.js"),__vite__mapDeps([22,14,15,3,17,11,12,0,1,2,4]))),uN=Q(()=>X(()=>import("./Faqs-DN4tIka3.js"),__vite__mapDeps([23,14,15,3,17]))),cN=Q(()=>X(()=>import("./Partners-Cm2S6bro.js"),__vite__mapDeps([24,11,12,14,15,3,17]))),dN=Q(()=>X(()=>import("./Downloads-MkUPdkz-.js"),__vite__mapDeps([25,6,14,15,3,17,2]))),fN=Q(()=>X(()=>import("./HomeSections-BowTW1QH.js"),__vite__mapDeps([26,27,13,28]))),hN=Q(()=>X(()=>import("./ContactRequests-C9ur1i_c.js"),__vite__mapDeps([29,9]))),mN=Q(()=>X(()=>import("./AccountSettings-BjOWslDE.js"),[])),pN=Q(()=>X(()=>import("./AdminUsers-DYpKky5w.js"),[])),gN=Q(()=>X(()=>import("./PermissionGroups-7L2JMWh8.js"),[])),yN=Q(()=>X(()=>import("./SettingsLayout-CRAynHUX.js"),[])),ml=Q(()=>X(()=>import("./WebsiteSettings-C9ZvZCtS.js"),__vite__mapDeps([30,11,12,28]))),xN=Q(()=>X(()=>import("./LegalSettings-BKkWnLFq.js"),__vite__mapDeps([31,27]))),vN=Q(()=>X(()=>import("./UpdateSettings-_gVIigY0.js"),[])),wN=Q(()=>X(()=>import("./EmailSettings-CnX83jWY.js"),__vite__mapDeps([32,27]))),kN=Q(()=>X(()=>import("./DatabaseSettings-Dd8MgFmo.js"),__vite__mapDeps([33,8]))),bN=Q(()=>X(()=>import("./ExportImportSettings-Dz31tCNC.js"),[])),SN=Q(()=>X(()=>import("./MaintenanceSettings-Dou4llm0.js"),[])),jN=Q(()=>X(()=>import("./ResetSettings-BYj4e5tP.js"),[])),PN=l.jsx("div",{className:"min-h-screen bg-white dark:bg-neutral-950"});function CN(){const{packageId:e}=$c();return l.jsx(Zn,{to:`/admin/packages?paket=${e}`,replace:!0})}function TN(){return l.jsxs(lj,{reducedMotion:"user",children:[l.jsx(FP,{}),l.jsx(BP,{}),l.jsx(KP,{children:l.jsx(p.Suspense,{fallback:PN,children:l.jsxs(Zw,{children:[l.jsx(B,{path:"/setup",element:l.jsx(JE,{})}),l.jsxs(B,{element:l.jsx(GT,{}),children:[l.jsx(B,{path:"/",element:l.jsx(yE,{})}),l.jsx(B,{path:"/fahrzeuge",element:l.jsx(xE,{})}),l.jsx(B,{path:"/fahrzeuge/:brandSlug",element:l.jsx(vE,{})}),l.jsx(B,{path:"/fahrzeuge/:brandSlug/:modelSlug",element:l.jsx(RE,{})}),l.jsx(B,{path:"/galerie",element:l.jsx(GE,{})}),l.jsx(B,{path:"/galerie/:brandSlug",element:l.jsx(KE,{})}),l.jsx(B,{path:"/galerie/:brandSlug/:projectSlug",element:l.jsx(qE,{})}),l.jsx(B,{path:"/leistungen",element:l.jsx(OE,{})}),l.jsx(B,{path:"/kontakt",element:l.jsx(WE,{})}),l.jsx(B,{path:"/downloads",element:l.jsx(YE,{})}),l.jsx(B,{path:"/impressum",element:l.jsx(XE,{})}),l.jsx(B,{path:"/datenschutz",element:l.jsx(ZE,{})}),l.jsx(B,{path:"/agb",element:l.jsx(QE,{})}),l.jsx(B,{path:"*",element:l.jsx(Nd,{})})]}),l.jsx(B,{path:"/admin/login",element:l.jsx(eN,{})}),l.jsx(B,{path:"/admin",element:l.jsx(JT,{}),children:l.jsxs(B,{element:l.jsx(QT,{}),children:[l.jsx(B,{index:!0,element:l.jsx(tN,{})}),l.jsx(B,{path:"account",element:l.jsx(mN,{})}),l.jsx(B,{path:"brands",element:l.jsx(fe,{permission:"brands.manage",children:l.jsx(nN,{})})}),l.jsx(B,{path:"models",element:l.jsx(fe,{permission:"models.manage",children:l.jsx(rN,{})})}),l.jsx(B,{path:"gallery-brands",element:l.jsx(fe,{permission:"gallery.manage",children:l.jsx(sN,{})})}),l.jsx(B,{path:"gallery-projects",element:l.jsx(fe,{permission:"gallery.manage",children:l.jsx(iN,{})})}),l.jsx(B,{path:"gallery-projects/:projectId/photos",element:l.jsx(fe,{permission:"gallery.manage",children:l.jsx(oN,{})})}),l.jsx(B,{path:"packages",element:l.jsx(fe,{permission:"packages.manage",children:l.jsx(aN,{})})}),l.jsx(B,{path:"packages/:packageId/*",element:l.jsx(CN,{})}),l.jsx(B,{path:"services",element:l.jsx(fe,{permission:"services.manage",children:l.jsx(lN,{})})}),l.jsx(B,{path:"faqs",element:l.jsx(fe,{permission:"content.manage",children:l.jsx(uN,{})})}),l.jsx(B,{path:"partners",element:l.jsx(fe,{permission:"content.manage",children:l.jsx(cN,{})})}),l.jsx(B,{path:"downloads",element:l.jsx(fe,{permission:"downloads.manage",children:l.jsx(dN,{})})}),l.jsx(B,{path:"home-sections",element:l.jsx(fe,{permission:"content.manage",children:l.jsx(fN,{})})}),l.jsx(B,{path:"contact-requests",element:l.jsx(fe,{permission:"contact.manage",children:l.jsx(hN,{})})}),l.jsx(B,{path:"users",element:l.jsx(fe,{permission:"users.manage",children:l.jsx(pN,{})})}),l.jsx(B,{path:"permission-groups",element:l.jsx(fe,{permission:"permission_groups.manage",children:l.jsx(gN,{})})}),l.jsxs(B,{path:"settings",element:l.jsx(fe,{permission:["settings.manage","system.admin","system.update"],children:l.jsx(yN,{})}),children:[l.jsx(B,{index:!0,element:l.jsx(Zn,{to:"company",replace:!0})}),l.jsx(B,{path:"website",element:l.jsx(Zn,{to:"../company",replace:!0})}),l.jsx(B,{path:"company",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(ml,{section:"company"})})}),l.jsx(B,{path:"design",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(ml,{section:"design"})})}),l.jsx(B,{path:"legal",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(xN,{})})}),l.jsx(B,{path:"maintenance",element:l.jsx(fe,{permission:"settings.manage",children:l.jsx(SN,{})})}),l.jsx(B,{path:"google",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(ml,{section:"google"})})}),l.jsx(B,{path:"email",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(wN,{})})}),l.jsx(B,{path:"database",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(kN,{})})}),l.jsx(B,{path:"export-import",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(bN,{})})}),l.jsx(B,{path:"update",element:l.jsx(fe,{permission:"system.update",children:l.jsx(vN,{})})}),l.jsx(B,{path:"reset",element:l.jsx(fe,{permission:"system.admin",children:l.jsx(jN,{})})})]})]})})]})})})]})}pl.createRoot(document.getElementById("root")).render(l.jsx(rp.StrictMode,{children:l.jsx(ok,{basename:"/".replace(/\/$/,"")||"/",children:l.jsx(nT,{children:l.jsx(aT,{children:l.jsx(pT,{children:l.jsx(TN,{})})})})})}));export{fx as $,HP as A,Gm as B,yC as C,FE as D,bC as E,EN as F,ee as G,eC as H,zo as I,nC as J,iC as K,U as L,aC as M,Nd as N,Uc as O,dC as P,pC as Q,ze as R,Cx as S,cx as T,wC as U,jC as V,CC as W,EC as X,_C as Y,Hu as Z,dx as _,Lt as a,RC as a0,VC as a1,OC as a2,Jn as a3,HC as a4,UC as a5,GC as a6,qC as a7,XC as a8,QC as a9,eT as aa,QP as ab,_N as ac,ZP as ad,rr as b,ce as c,Fm as d,ga as e,$c as f,Oc as g,qr as h,oa as i,l as j,Zn as k,Am as l,Uu as m,AN as n,DN as o,RN as p,dk as q,p as r,uC as s,hC as t,rt as u,rp as v,LN as w,nt as x,jx as y,MN as z}; diff --git a/hifi/assets/music-DPTNgOWL.js b/hifi/assets/music-B3GiJs_4.js similarity index 98% rename from hifi/assets/music-DPTNgOWL.js rename to hifi/assets/music-B3GiJs_4.js index 6ad0944..6e10133 100644 --- a/hifi/assets/music-DPTNgOWL.js +++ b/hifi/assets/music-B3GiJs_4.js @@ -1,4 +1,4 @@ -import{G as a}from"./index-Tg8iNBwT.js";/** +import{G as a}from"./index-Cc1wEeIX.js";/** * @license lucide-react v1.23.0 - ISC * * This source code is licensed under the ISC license. diff --git a/hifi/assets/sortable.esm-DhUbHeHx.js b/hifi/assets/sortable.esm-D8IvDAze.js similarity index 99% rename from hifi/assets/sortable.esm-DhUbHeHx.js rename to hifi/assets/sortable.esm-D8IvDAze.js index 6b47689..d469387 100644 --- a/hifi/assets/sortable.esm-DhUbHeHx.js +++ b/hifi/assets/sortable.esm-D8IvDAze.js @@ -1,4 +1,4 @@ -import{r as c,v as P,g as Oe}from"./index-Tg8iNBwT.js";function Rn(){for(var e=arguments.length,t=new Array(e),n=0;nr=>{t.forEach(o=>o(r))},t)}const et=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function me(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function pt(e){return"nodeType"in e}function B(e){var t,n;return e?me(e)?e:pt(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function bt(e){const{Document:t}=B(e);return e instanceof t}function Be(e){return me(e)?!1:e instanceof B(e).HTMLElement}function Ut(e){return e instanceof B(e).SVGElement}function ye(e){return e?me(e)?e.document:pt(e)?bt(e)?e:Be(e)||Ut(e)?e.ownerDocument:document:document:document}const Q=et?c.useLayoutEffect:c.useEffect;function wt(e){const t=c.useRef(e);return Q(()=>{t.current=e}),c.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o{e.current=setInterval(r,o)},[]),n=c.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function ke(e,t){t===void 0&&(t=[e]);const n=c.useRef(e);return Q(()=>{n.current!==e&&(n.current=e)},t),n}function Fe(e,t){const n=c.useRef();return c.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function Ge(e){const t=wt(e),n=c.useRef(null),r=c.useCallback(o=>{o!==n.current&&(t==null||t(o,n.current)),n.current=o},[]);return[n,r]}function dt(e){const t=c.useRef();return c.useEffect(()=>{t.current=e},[e]),t.current}let at={};function $e(e,t){return c.useMemo(()=>{if(t)return t;const n=at[e]==null?0:at[e]+1;return at[e]=n,e+"-"+n},[e,t])}function Wt(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o{const a=Object.entries(s);for(const[l,u]of a){const f=i[l];f!=null&&(i[l]=f+e*u)}return i},{...t})}}const we=Wt(1),ze=Wt(-1);function En(e){return"clientX"in e&&"clientY"in e}function mt(e){if(!e)return!1;const{KeyboardEvent:t}=B(e.target);return t&&e instanceof t}function Mn(e){if(!e)return!1;const{TouchEvent:t}=B(e.target);return t&&e instanceof t}function ft(e){if(Mn(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return En(e)?{x:e.clientX,y:e.clientY}:null}const Je=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Je.Translate.toString(e),Je.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Ot="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function In(e){return e.matches(Ot)?e:e.querySelector(Ot)}const An={display:"none"};function On(e){let{id:t,value:n}=e;return P.createElement("div",{id:t,style:An},n)}function Tn(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return P.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":!0},n)}function Nn(){const[e,t]=c.useState("");return{announce:c.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const Ht=c.createContext(null);function Ln(e){const t=c.useContext(Ht);c.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of ");return t(e)},[e,t])}function kn(){const[e]=c.useState(()=>new Set),t=c.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[c.useCallback(r=>{let{type:o,event:i}=r;e.forEach(s=>{var a;return(a=s[o])==null?void 0:a.call(s,i)})},[e]),t]}const zn={draggable:` +import{r as c,v as P,g as Oe}from"./index-Cc1wEeIX.js";function Rn(){for(var e=arguments.length,t=new Array(e),n=0;nr=>{t.forEach(o=>o(r))},t)}const et=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function me(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function pt(e){return"nodeType"in e}function B(e){var t,n;return e?me(e)?e:pt(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function bt(e){const{Document:t}=B(e);return e instanceof t}function Be(e){return me(e)?!1:e instanceof B(e).HTMLElement}function Ut(e){return e instanceof B(e).SVGElement}function ye(e){return e?me(e)?e.document:pt(e)?bt(e)?e:Be(e)||Ut(e)?e.ownerDocument:document:document:document}const Q=et?c.useLayoutEffect:c.useEffect;function wt(e){const t=c.useRef(e);return Q(()=>{t.current=e}),c.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o{e.current=setInterval(r,o)},[]),n=c.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function ke(e,t){t===void 0&&(t=[e]);const n=c.useRef(e);return Q(()=>{n.current!==e&&(n.current=e)},t),n}function Fe(e,t){const n=c.useRef();return c.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function Ge(e){const t=wt(e),n=c.useRef(null),r=c.useCallback(o=>{o!==n.current&&(t==null||t(o,n.current)),n.current=o},[]);return[n,r]}function dt(e){const t=c.useRef();return c.useEffect(()=>{t.current=e},[e]),t.current}let at={};function $e(e,t){return c.useMemo(()=>{if(t)return t;const n=at[e]==null?0:at[e]+1;return at[e]=n,e+"-"+n},[e,t])}function Wt(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o{const a=Object.entries(s);for(const[l,u]of a){const f=i[l];f!=null&&(i[l]=f+e*u)}return i},{...t})}}const we=Wt(1),ze=Wt(-1);function En(e){return"clientX"in e&&"clientY"in e}function mt(e){if(!e)return!1;const{KeyboardEvent:t}=B(e.target);return t&&e instanceof t}function Mn(e){if(!e)return!1;const{TouchEvent:t}=B(e.target);return t&&e instanceof t}function ft(e){if(Mn(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return En(e)?{x:e.clientX,y:e.clientY}:null}const Je=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[Je.Translate.toString(e),Je.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Ot="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function In(e){return e.matches(Ot)?e:e.querySelector(Ot)}const An={display:"none"};function On(e){let{id:t,value:n}=e;return P.createElement("div",{id:t,style:An},n)}function Tn(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return P.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":!0},n)}function Nn(){const[e,t]=c.useState("");return{announce:c.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const Ht=c.createContext(null);function Ln(e){const t=c.useContext(Ht);c.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of ");return t(e)},[e,t])}function kn(){const[e]=c.useState(()=>new Set),t=c.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[c.useCallback(r=>{let{type:o,event:i}=r;e.forEach(s=>{var a;return(a=s[o])==null?void 0:a.call(s,i)})},[e]),t]}const zn={draggable:` To pick up a draggable item, press the space bar. While dragging, use the arrow keys to move the item. Press space again to drop the item in its new position, or press escape to cancel. diff --git a/hifi/assets/trash-2-CnvKO1vQ.js b/hifi/assets/trash-2-UGYx0Sek.js similarity index 96% rename from hifi/assets/trash-2-CnvKO1vQ.js rename to hifi/assets/trash-2-UGYx0Sek.js index df2157f..dc6bec7 100644 --- a/hifi/assets/trash-2-CnvKO1vQ.js +++ b/hifi/assets/trash-2-UGYx0Sek.js @@ -1,4 +1,4 @@ -import{G as a}from"./index-Tg8iNBwT.js";/** +import{G as a}from"./index-Cc1wEeIX.js";/** * @license lucide-react v1.23.0 - ISC * * This source code is licensed under the ISC license. diff --git a/hifi/index.html b/hifi/index.html index d9bf1b1..526e960 100644 --- a/hifi/index.html +++ b/hifi/index.html @@ -49,8 +49,8 @@ "sameAs": ["https://www.youtube.com/@hifiplanet2812"] } - - + +