"use strict";(self["webpackChunkcigar_finder_frontend"]=self["webpackChunkcigar_finder_frontend"]||[]).push([[114],{1950:function(e,s,i){i.r(s),i.d(s,{default:function(){return ge}});var t=i(641),a=i(33),l=i(3751);const o={class:"claim-page"},n={key:0,class:"breadcrumb"},r={key:1,class:"claim-container"},d={class:"claim-header"},u={key:0,class:"already-claimed-card"},c={key:1},p={key:0,class:"step-section"},h={class:"methods-grid"},k={class:"method-info"},g={key:0},b={key:1,class:"method-unavailable"},m={key:0,class:"method-check"},v={class:"method-info"},L={key:0},y={key:1},f={key:0,class:"method-check"},C={class:"method-info"},w={key:0},_={key:1},F={key:0,class:"method-check"},E={key:0,class:"method-check"},S=["disabled"],X={key:1,class:"step-section"},U={key:0,class:"verify-card"},W={class:"code-input-group"},x=["disabled"],z={key:1,class:"verify-card"},P={key:0,class:"email-entry"},T=["disabled"],V={key:1},I={key:2,class:"code-input-group"},M=["disabled"],D={key:2,class:"verify-card"},B={key:0,class:"no-website-notice"},Q={key:1},O={class:"meta-code-block"},j=["disabled"],N={key:3,class:"verify-card"},q={key:0,class:"upload-placeholder"},J={key:1,class:"upload-preview"},$=["disabled"],A={key:2,class:"step-section success-section"},R={key:0},H={key:1},Y={key:3,class:"error-msg"},G={key:2,class:"benefits-card"},K={key:3,class:"faq-section"},Z={class:"faq-item"},ee={class:"faq-toggle"},se={class:"faq-answer"},ie={class:"faq-item"},te={class:"faq-toggle"},ae={class:"faq-answer"},le={class:"faq-item"},oe={class:"faq-toggle"},ne={class:"faq-answer"},re={key:2,class:"loading-state"},de={key:3,class:"not-found-state"};function ue(e,s,i,ue,ce,pe){const he=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[ce.lounge?((0,t.uX)(),(0,t.CE)("nav",n,[(0,t.bF)(he,{to:"/"},{default:(0,t.k6)((()=>s[25]||(s[25]=[(0,t.eW)("Home")]))),_:1}),s[27]||(s[27]=(0,t.Lk)("span",{class:"sep"},"/",-1)),(0,t.bF)(he,{to:"/store-locator"},{default:(0,t.k6)((()=>s[26]||(s[26]=[(0,t.eW)("Store Locator")]))),_:1}),s[28]||(s[28]=(0,t.Lk)("span",{class:"sep"},"/",-1)),(0,t.bF)(he,{to:pe.cityLink},{default:(0,t.k6)((()=>[(0,t.eW)((0,a.v_)(ce.lounge.city)+", "+(0,a.v_)(ce.lounge.state),1)])),_:1},8,["to"]),s[29]||(s[29]=(0,t.Lk)("span",{class:"sep"},"/",-1)),(0,t.bF)(he,{to:pe.loungeLink},{default:(0,t.k6)((()=>[(0,t.eW)((0,a.v_)(ce.lounge.name),1)])),_:1},8,["to"]),s[30]||(s[30]=(0,t.Lk)("span",{class:"sep"},"/",-1)),s[31]||(s[31]=(0,t.Lk)("span",{class:"current"},"Claim",-1))])):(0,t.Q3)("",!0),ce.lounge?((0,t.uX)(),(0,t.CE)("div",r,[(0,t.Lk)("div",d,[(0,t.Lk)("h1",null,"Claim "+(0,a.v_)(ce.lounge.name),1),s[32]||(s[32]=(0,t.Lk)("p",{class:"claim-subtitle"}," Verify ownership to manage your business listing on CigarFinder. ",-1))]),ce.lounge.claimed?((0,t.uX)(),(0,t.CE)("div",u,[s[36]||(s[36]=(0,t.Lk)("div",{class:"claimed-icon"},"✓",-1)),s[37]||(s[37]=(0,t.Lk)("h2",null,"This business has already been claimed",-1)),(0,t.Lk)("p",null,[s[34]||(s[34]=(0,t.eW)("If you believe this is an error, please ")),(0,t.bF)(he,{to:"/contact"},{default:(0,t.k6)((()=>s[33]||(s[33]=[(0,t.eW)("contact us")]))),_:1}),s[35]||(s[35]=(0,t.eW)("."))])])):((0,t.uX)(),(0,t.CE)("div",c,["choose"===ce.step?((0,t.uX)(),(0,t.CE)("div",p,[s[52]||(s[52]=(0,t.Lk)("h2",{class:"step-title"},"Choose a verification method",-1)),(0,t.Lk)("div",h,[(0,t.Lk)("div",{class:(0,a.C4)(["method-card",{selected:"phone_sms"===ce.selectedMethod}]),onClick:s[0]||(s[0]=e=>pe.selectMethod("phone_sms"))},[s[41]||(s[41]=(0,t.Lk)("div",{class:"method-icon"},"☎",-1)),(0,t.Lk)("div",k,[s[40]||(s[40]=(0,t.Lk)("h3",null,"Phone Call",-1)),ce.lounge.phone?((0,t.uX)(),(0,t.CE)("p",g,[s[38]||(s[38]=(0,t.eW)(" We'll call ")),(0,t.Lk)("strong",null,(0,a.v_)(pe.maskPhone(ce.lounge.phone)),1),s[39]||(s[39]=(0,t.eW)(" with a verification code. "))])):((0,t.uX)(),(0,t.CE)("p",b,"No phone number on file for this listing."))]),"phone_sms"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",m,"✓")):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,a.C4)(["method-card",{selected:"domain_email"===ce.selectedMethod}]),onClick:s[1]||(s[1]=e=>pe.selectMethod("domain_email"))},[s[45]||(s[45]=(0,t.Lk)("div",{class:"method-icon"},"✉",-1)),(0,t.Lk)("div",v,[s[44]||(s[44]=(0,t.Lk)("h3",null,"Business Email",-1)),ce.lounge.website?((0,t.uX)(),(0,t.CE)("p",L,[s[42]||(s[42]=(0,t.eW)(" We'll send a code to your email at ")),(0,t.Lk)("strong",null,"@"+(0,a.v_)(pe.extractDomain(ce.lounge.website)),1),s[43]||(s[43]=(0,t.eW)(". "))])):((0,t.uX)(),(0,t.CE)("p",y," Enter your business email to receive a verification code. "))]),"domain_email"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",f,"✓")):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,a.C4)(["method-card",{selected:"website_meta"===ce.selectedMethod}]),onClick:s[2]||(s[2]=e=>pe.selectMethod("website_meta"))},[s[49]||(s[49]=(0,t.Lk)("div",{class:"method-icon"},"</>",-1)),(0,t.Lk)("div",C,[s[48]||(s[48]=(0,t.Lk)("h3",null,"Website Meta Tag",-1)),ce.lounge.website?((0,t.uX)(),(0,t.CE)("p",w,[s[46]||(s[46]=(0,t.eW)(" Add a meta tag to ")),(0,t.Lk)("strong",null,(0,a.v_)(pe.extractDomain(ce.lounge.website)),1),s[47]||(s[47]=(0,t.eW)(" to verify ownership. "))])):((0,t.uX)(),(0,t.CE)("p",_," Add your website first, then place a meta tag to verify ownership. "))]),"website_meta"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",F,"✓")):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,a.C4)(["method-card",{selected:"manual_review"===ce.selectedMethod}]),onClick:s[3]||(s[3]=e=>pe.selectMethod("manual_review"))},[s[50]||(s[50]=(0,t.Lk)("div",{class:"method-icon"},"📄",-1)),s[51]||(s[51]=(0,t.Lk)("div",{class:"method-info"},[(0,t.Lk)("h3",null,"Manual Review"),(0,t.Lk)("p",null,"Upload a document (utility bill, business license) proving ownership. Reviewed in 24-48 hours.")],-1)),"manual_review"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",E,"✓")):(0,t.Q3)("",!0)],2)]),(0,t.Lk)("button",{class:"btn-primary",disabled:!ce.selectedMethod,onClick:s[4]||(s[4]=(...e)=>pe.submitClaim&&pe.submitClaim(...e))}," Continue with "+(0,a.v_)(pe.methodLabel),9,S)])):(0,t.Q3)("",!0),"verify"===ce.step?((0,t.uX)(),(0,t.CE)("div",X,["phone_sms"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",U,[s[55]||(s[55]=(0,t.Lk)("h2",null,"Enter your verification code",-1)),(0,t.Lk)("p",null,[s[53]||(s[53]=(0,t.eW)("We're calling ")),(0,t.Lk)("strong",null,(0,a.v_)(pe.maskPhone(ce.lounge.phone)),1),s[54]||(s[54]=(0,t.eW)(" now. Enter the 6-digit code you hear."))]),(0,t.Lk)("div",W,[(0,t.bo)((0,t.Lk)("input",{"onUpdate:modelValue":s[5]||(s[5]=e=>ce.verificationCode=e),type:"text",maxlength:"6",placeholder:"000000",class:"code-input",onKeyup:s[6]||(s[6]=(0,l.jR)(((...e)=>pe.verifyClaim&&pe.verifyClaim(...e)),["enter"]))},null,544),[[l.Jo,ce.verificationCode]])]),(0,t.Lk)("button",{class:"btn-primary",disabled:ce.verificationCode.length<6||ce.verifying,onClick:s[7]||(s[7]=(...e)=>pe.verifyClaim&&pe.verifyClaim(...e))},(0,a.v_)(ce.verifying?"Verifying...":"Verify"),9,x)])):(0,t.Q3)("",!0),"domain_email"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",z,[s[59]||(s[59]=(0,t.Lk)("h2",null,"Check your business email",-1)),ce.lounge.website?((0,t.uX)(),(0,t.CE)("div",V,[(0,t.Lk)("p",null,[s[57]||(s[57]=(0,t.eW)("We've sent a verification code to your email at ")),(0,t.Lk)("strong",null,"@"+(0,a.v_)(pe.extractDomain(ce.lounge.website)),1),s[58]||(s[58]=(0,t.eW)("."))])])):((0,t.uX)(),(0,t.CE)("div",P,[s[56]||(s[56]=(0,t.Lk)("p",null,"Enter your business email address:",-1)),(0,t.bo)((0,t.Lk)("input",{"onUpdate:modelValue":s[8]||(s[8]=e=>ce.businessEmail=e),type:"email",placeholder:"you@yourbusiness.com",class:"text-input"},null,512),[[l.Jo,ce.businessEmail]]),(0,t.Lk)("button",{class:"btn-secondary",onClick:s[9]||(s[9]=(...e)=>pe.sendEmailCode&&pe.sendEmailCode(...e)),disabled:!ce.businessEmail}," Send Code ",8,T)])),ce.emailCodeSent||ce.lounge.website?((0,t.uX)(),(0,t.CE)("div",I,[(0,t.bo)((0,t.Lk)("input",{"onUpdate:modelValue":s[10]||(s[10]=e=>ce.verificationCode=e),type:"text",maxlength:"6",placeholder:"000000",class:"code-input",onKeyup:s[11]||(s[11]=(0,l.jR)(((...e)=>pe.verifyClaim&&pe.verifyClaim(...e)),["enter"]))},null,544),[[l.Jo,ce.verificationCode]])])):(0,t.Q3)("",!0),ce.emailCodeSent||ce.lounge.website?((0,t.uX)(),(0,t.CE)("button",{key:3,class:"btn-primary",disabled:ce.verificationCode.length<6||ce.verifying,onClick:s[12]||(s[12]=(...e)=>pe.verifyClaim&&pe.verifyClaim(...e))},(0,a.v_)(ce.verifying?"Verifying...":"Verify"),9,M)):(0,t.Q3)("",!0)])):(0,t.Q3)("",!0),"website_meta"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",D,[s[68]||(s[68]=(0,t.Lk)("h2",null,"Add this meta tag to your website",-1)),ce.lounge.website?((0,t.uX)(),(0,t.CE)("div",Q,[(0,t.Lk)("p",null,[s[63]||(s[63]=(0,t.eW)("Place this tag in the ")),s[64]||(s[64]=(0,t.Lk)("code",null,"<head>",-1)),s[65]||(s[65]=(0,t.eW)(" section of ")),(0,t.Lk)("strong",null,(0,a.v_)(ce.lounge.website),1),s[66]||(s[66]=(0,t.eW)(":"))]),(0,t.Lk)("div",O,[(0,t.Lk)("code",null,(0,a.v_)(ce.metaTag),1),(0,t.Lk)("button",{class:"btn-copy",onClick:s[13]||(s[13]=(...e)=>pe.copyMeta&&pe.copyMeta(...e))},(0,a.v_)(ce.copied?"Copied!":"Copy"),1)]),s[67]||(s[67]=(0,t.Lk)("p",{class:"meta-hint"},"Once the tag is live, click the button below and we'll check instantly.",-1)),(0,t.Lk)("button",{class:"btn-primary",disabled:ce.verifying,onClick:s[14]||(s[14]=(...e)=>pe.verifyClaim&&pe.verifyClaim(...e))},(0,a.v_)(ce.verifying?"Checking...":"Verify Meta Tag"),9,j)])):((0,t.uX)(),(0,t.CE)("div",B,[(0,t.Lk)("p",null,[s[61]||(s[61]=(0,t.eW)(" No website is currently listed for this business. Please ")),(0,t.bF)(he,{to:pe.loungeLink},{default:(0,t.k6)((()=>s[60]||(s[60]=[(0,t.eW)("update your listing")]))),_:1},8,["to"]),s[62]||(s[62]=(0,t.eW)(" to add a website first, then return here to verify via meta tag. "))])]))])):(0,t.Q3)("",!0),"manual_review"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",N,[s[71]||(s[71]=(0,t.Lk)("h2",null,"Upload verification document",-1)),s[72]||(s[72]=(0,t.Lk)("p",null,"Upload a business license, utility bill, or official document showing the business name and address.",-1)),(0,t.Lk)("div",{class:"upload-area",onClick:s[17]||(s[17]=s=>e.$refs.fileInput.click()),onDragover:s[18]||(s[18]=(0,l.D$)((()=>{}),["prevent"])),onDrop:s[19]||(s[19]=(0,l.D$)(((...e)=>pe.handleDrop&&pe.handleDrop(...e)),["prevent"]))},[(0,t.Lk)("input",{ref:"fileInput",type:"file",accept:".pdf,.jpg,.jpeg,.png",onChange:s[15]||(s[15]=(...e)=>pe.handleFile&&pe.handleFile(...e)),hidden:""},null,544),ce.uploadedFile?((0,t.uX)(),(0,t.CE)("div",J,[s[70]||(s[70]=(0,t.Lk)("span",null,"📄",-1)),(0,t.Lk)("span",null,(0,a.v_)(ce.uploadedFile.name),1),(0,t.Lk)("button",{class:"btn-remove",onClick:s[16]||(s[16]=(0,l.D$)((e=>ce.uploadedFile=null),["stop"]))},"✕")])):((0,t.uX)(),(0,t.CE)("div",q,s[69]||(s[69]=[(0,t.Lk)("span",{class:"upload-icon"},"📎",-1),(0,t.Lk)("p",null,"Click or drag a file here",-1),(0,t.Lk)("p",{class:"upload-hint"},"PDF, JPG, or PNG — max 10 MB",-1)])))],32),(0,t.Lk)("button",{class:"btn-primary",disabled:!ce.uploadedFile||ce.verifying,onClick:s[20]||(s[20]=(...e)=>pe.verifyClaim&&pe.verifyClaim(...e))},(0,a.v_)(ce.verifying?"Submitting...":"Submit for Review"),9,$)])):(0,t.Q3)("",!0),(0,t.Lk)("button",{class:"btn-back",onClick:s[21]||(s[21]=e=>{ce.step="choose",ce.verificationCode="",ce.errorMsg=""})}," ← Back to methods ")])):(0,t.Q3)("",!0),"success"===ce.step?((0,t.uX)(),(0,t.CE)("div",A,[s[76]||(s[76]=(0,t.Lk)("div",{class:"success-icon"},"✓",-1)),(0,t.Lk)("h2",null,(0,a.v_)("manual_review"===ce.selectedMethod?"Submission Received":"Verification Successful"),1),"manual_review"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("p",R," Your documents have been submitted for review. You'll receive an email within 24-48 hours. ")):((0,t.uX)(),(0,t.CE)("p",H,[s[73]||(s[73]=(0,t.eW)(" You now have full control of the ")),(0,t.Lk)("strong",null,(0,a.v_)(ce.lounge.name),1),s[74]||(s[74]=(0,t.eW)(" listing. "))])),(0,t.bF)(he,{to:pe.loungeLink,class:"btn-primary"},{default:(0,t.k6)((()=>s[75]||(s[75]=[(0,t.eW)("Go to Your Listing")]))),_:1},8,["to"])])):(0,t.Q3)("",!0),ce.errorMsg?((0,t.uX)(),(0,t.CE)("div",Y,(0,a.v_)(ce.errorMsg),1)):(0,t.Q3)("",!0)])),ce.lounge.claimed?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",G,s[77]||(s[77]=[(0,t.Fv)('<h3 class="benefits-title" data-v-022807ae>What you get when you verify</h3><ul class="benefits-list" data-v-022807ae><li data-v-022807ae><span class="check-icon" data-v-022807ae>✓</span> Update your hours, photos, and description </li><li data-v-022807ae><span class="check-icon" data-v-022807ae>✓</span> Respond to customer reviews </li><li data-v-022807ae><span class="check-icon" data-v-022807ae>✓</span> Get a verified badge on your listing </li><li data-v-022807ae><span class="check-icon" data-v-022807ae>✓</span> Add a free backlink to get premium features </li><li data-v-022807ae><span class="check-icon" data-v-022807ae>✓</span> Promote events and specials </li></ul>',2)]))),ce.lounge.claimed?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",K,[s[81]||(s[81]=(0,t.Lk)("h3",{class:"faq-title"},"Frequently Asked Questions",-1)),(0,t.Lk)("div",Z,[(0,t.Lk)("button",{class:"faq-question",onClick:s[22]||(s[22]=e=>pe.toggleFaq(0))},[s[78]||(s[78]=(0,t.eW)(" How long does verification take? ")),(0,t.Lk)("span",ee,(0,a.v_)(ce.faqOpen[0]?"−":"+"),1)]),(0,t.bo)((0,t.Lk)("div",se," Phone and email verification is instant. Website meta tag verification is instant once the tag is detected on your site. Manual review takes 24–48 hours. ",512),[[l.aG,ce.faqOpen[0]]])]),(0,t.Lk)("div",ie,[(0,t.Lk)("button",{class:"faq-question",onClick:s[23]||(s[23]=e=>pe.toggleFaq(1))},[s[79]||(s[79]=(0,t.eW)(" What if I don't have access to the business phone? ")),(0,t.Lk)("span",te,(0,a.v_)(ce.faqOpen[1]?"−":"+"),1)]),(0,t.bo)((0,t.Lk)("div",ae," Try email or website verification instead. If none of those work, submit a manual review with a business license or utility bill and we'll verify you within 24–48 hours. ",512),[[l.aG,ce.faqOpen[1]]])]),(0,t.Lk)("div",le,[(0,t.Lk)("button",{class:"faq-question",onClick:s[24]||(s[24]=e=>pe.toggleFaq(2))},[s[80]||(s[80]=(0,t.eW)(" Can multiple people manage one listing? ")),(0,t.Lk)("span",oe,(0,a.v_)(ce.faqOpen[2]?"−":"+"),1)]),(0,t.bo)((0,t.Lk)("div",ne," Currently each listing supports one verified owner. Team management features are coming soon. Contact us if you need to transfer ownership. ",512),[[l.aG,ce.faqOpen[2]]])])]))])):ce.loading?((0,t.uX)(),(0,t.CE)("div",re,s[82]||(s[82]=[(0,t.Lk)("p",null,"Loading business details...",-1)]))):((0,t.uX)(),(0,t.CE)("div",de,[s[84]||(s[84]=(0,t.Lk)("h2",null,"Business not found",-1)),s[85]||(s[85]=(0,t.Lk)("p",null,"We couldn't find this listing. It may have been removed.",-1)),(0,t.bF)(he,{to:"/store-locator",class:"btn-primary"},{default:(0,t.k6)((()=>s[83]||(s[83]=[(0,t.eW)("Back to Store Locator")]))),_:1})]))])}var ce=i(7465),pe={name:"BusinessClaim",data(){return{lounge:null,loading:!0,step:"choose",selectedMethod:null,verificationCode:"",verifying:!1,errorMsg:"",copied:!1,uploadedFile:null,businessEmail:"",emailCodeSent:!1,metaTag:"",faqOpen:[!1,!1,!1],codeSent:!1,claimId:null,submitting:!1}},computed:{isLoggedIn(){return!!localStorage.getItem("business_session_token")},token(){return localStorage.getItem("business_session_token")},methodLabel(){const e={phone_sms:"Phone Verification",domain_email:"Business Email",website_meta:"Website Meta Tag",manual_review:"Manual Review"};return e[this.selectedMethod]||"Selected Method"},loungeLink(){return this.lounge?"/lounges/"+(this.lounge.slug||this.lounge.id):"/lounges"},cityLink(){if(!this.lounge)return"/lounges";const e=(this.lounge.city||"").toLowerCase().replace(/\s+/g,"-"),s=(this.lounge.state||"").toLowerCase();return"/lounges/"+e+"-"+s}},mounted(){document.title="Claim Your Business - CigarFinder",this.loadLounge()},methods:{async loadLounge(){this.loading=!0;try{const e=this.$route.params.id,s=await(0,ce.fetchData)(ce.baseUrl+"api/v1/lounges/"+e);this.lounge=s.lounge||null,this.lounge&&(this.metaTag='<meta name="cigarfinder-verify" content="'+this.lounge.id+'" />'),this.lounge||(this.errorMsg="Lounge not found")}catch(e){this.errorMsg="Failed to load lounge"}this.loading=!1},selectMethod(e){this.selectedMethod=e,this.errorMsg="",this.codeSent=!1,this.verificationCode=""},async submitClaim(){this.errorMsg="",this.submitting=!0;try{const e={verification_method:this.selectedMethod};"domain_email"===this.selectedMethod&&(e.email=this.businessEmail+"@"+this.extractDomain(this.lounge.website)),"manual_review"===this.selectedMethod&&(e.evidence_url=this.uploadedFile?"uploaded":"");const s=await fetch(ce.baseUrl+"api/v1/business/claim/"+this.lounge.id,{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify(e)}),i=await s.json();if(!s.ok)return this.errorMsg=i.errors?i.errors.join(", "):"Claim failed",void(this.submitting=!1);this.claimId=i.claim?i.claim.id:null,"website_meta"===this.selectedMethod&&i.claim&&(this.metaTag='<meta name="cigarfinder-verify" content="'+(i.claim.verification_code||this.lounge.id)+'">'),"manual_review"===this.selectedMethod?this.step="success":(this.codeSent=!0,this.step="verify")}catch(e){this.errorMsg="Network error"}finally{this.submitting=!1}},async sendEmailCode(){if(this.businessEmail){this.submitting=!0;try{const e={verification_method:"domain_email",email:this.businessEmail+"@"+this.extractDomain(this.lounge.website)},s=await fetch(ce.baseUrl+"api/v1/business/claim/"+this.lounge.id,{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify(e)}),i=await s.json();if(!s.ok)return this.errorMsg=i.errors?i.errors.join(", "):"Failed to send email",void(this.submitting=!1);this.claimId=i.claim?i.claim.id:null,this.emailCodeSent=!0,this.codeSent=!0}catch(e){this.errorMsg="Network error"}finally{this.submitting=!1}}},async verifyClaim(){this.verifying=!0,this.errorMsg="";try{const e={claim_id:this.claimId};"website_meta"!==this.selectedMethod&&(e.code=this.verificationCode);const s=await fetch(ce.baseUrl+"api/v1/business/verify_claim",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify(e)}),i=await s.json();if(!s.ok)return this.errorMsg=i.errors?i.errors.join(", "):"Verification failed",void(this.verifying=!1);this.step="success"}catch(e){this.errorMsg="Network error"}this.verifying=!1},maskPhone(e){if(!e)return"";const s=e.replace(/\D/g,"");return 11===s.length&&"1"===s[0]?"("+s.slice(1,4)+") ***-"+s.slice(-4):s.length>=10?"("+s.slice(0,3)+") ***-"+s.slice(-4):e},extractDomain(e){if(!e)return"";try{let s=e.replace(/^https?:\/\//,"").replace(/\/.*$/,"");return s=s.replace(/^www\./,""),s}catch{return e}},copyMeta(){navigator.clipboard.writeText(this.metaTag).then((()=>{this.copied=!0,setTimeout((()=>{this.copied=!1}),2e3)}))},handleFile(e){const s=e.target.files[0];s&&s.size<=10485760?this.uploadedFile=s:s&&(this.errorMsg="File must be under 10 MB.")},handleDrop(e){const s=e.dataTransfer.files[0];s&&s.size<=10485760?this.uploadedFile=s:s&&(this.errorMsg="File must be under 10 MB.")},toggleFaq(e){this.faqOpen[e]=!this.faqOpen[e]}}},he=i(6262);const ke=(0,he.A)(pe,[["render",ue],["__scopeId","data-v-022807ae"]]);var ge=ke},3533:function(e,s,i){i.r(s),i.d(s,{default:function(){return U}});var t=i(641),a=i(33),l=i(3751);const o={class:"biz-page"},n={class:"create-container"},r={key:0,class:"login-prompt"},d={class:"login-btns"},u={key:1,class:"success-card"},c={class:"form-section"},p={class:"form-group"},h={class:"form-row"},k={class:"form-group"},g={class:"form-row three"},b={class:"form-group"},m={class:"form-group small"},v={class:"form-group small"},L={class:"form-row"},y={class:"form-group"},f={class:"form-group"},C={key:0,class:"form-error"},w=["disabled"];function _(e,s,i,_,F,E){const S=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[(0,t.Lk)("div",n,[(0,t.bF)(S,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[8]||(s[8]=[(0,t.eW)("← Back to Dashboard")]))),_:1}),s[27]||(s[27]=(0,t.Lk)("h1",null,"Create a New Listing",-1)),s[28]||(s[28]=(0,t.Lk)("p",{class:"create-subtitle"},"Can't find your business in our directory? Add it here and we'll review it within 24-48 hours.",-1)),E.isLoggedIn?F.submitted?((0,t.uX)(),(0,t.CE)("div",u,[s[15]||(s[15]=(0,t.Lk)("div",{class:"success-icon"},"✓",-1)),s[16]||(s[16]=(0,t.Lk)("h2",null,"Listing Submitted!",-1)),(0,t.Lk)("p",null,[s[12]||(s[12]=(0,t.eW)("Your listing for ")),(0,t.Lk)("strong",null,(0,a.v_)(F.submittedName),1),s[13]||(s[13]=(0,t.eW)(" has been created! Redirecting you to add your business details..."))]),(0,t.bF)(S,{to:"/business/dashboard",class:"btn-primary"},{default:(0,t.k6)((()=>s[14]||(s[14]=[(0,t.eW)("Back to Dashboard")]))),_:1})])):((0,t.uX)(),(0,t.CE)("form",{key:2,onSubmit:s[7]||(s[7]=(0,l.D$)(((...e)=>E.submitListing&&E.submitListing(...e)),["prevent"])),class:"create-form"},[(0,t.Lk)("div",c,[s[25]||(s[25]=(0,t.Lk)("h2",null,"Business Information",-1)),(0,t.Lk)("div",p,[s[17]||(s[17]=(0,t.Lk)("label",null,"Business Name *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[0]||(s[0]=e=>F.form.name=e),required:"",placeholder:"e.g. The Cigar Bar"},null,512),[[l.Jo,F.form.name]])]),(0,t.Lk)("div",h,[(0,t.Lk)("div",k,[s[18]||(s[18]=(0,t.Lk)("label",null,"Street Address *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[1]||(s[1]=e=>F.form.address_line1=e),required:"",placeholder:"123 Main St"},null,512),[[l.Jo,F.form.address_line1]])])]),(0,t.Lk)("div",g,[(0,t.Lk)("div",b,[s[19]||(s[19]=(0,t.Lk)("label",null,"City *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[2]||(s[2]=e=>F.form.city=e),required:"",placeholder:"Miami"},null,512),[[l.Jo,F.form.city]])]),(0,t.Lk)("div",m,[s[20]||(s[20]=(0,t.Lk)("label",null,"State *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[3]||(s[3]=e=>F.form.state=e),required:"",maxlength:"2",placeholder:"FL"},null,512),[[l.Jo,F.form.state]])]),(0,t.Lk)("div",v,[s[21]||(s[21]=(0,t.Lk)("label",null,"Zip Code *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[4]||(s[4]=e=>F.form.zip_code=e),required:"",maxlength:"10",placeholder:"33101"},null,512),[[l.Jo,F.form.zip_code]])])]),(0,t.Lk)("div",L,[(0,t.Lk)("div",y,[s[22]||(s[22]=(0,t.Lk)("label",null,"Phone *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"tel","onUpdate:modelValue":s[5]||(s[5]=e=>F.form.phone=e),required:"",placeholder:"(305) 555-1234"},null,512),[[l.Jo,F.form.phone]])]),(0,t.Lk)("div",f,[s[24]||(s[24]=(0,t.Lk)("label",null,"Business Type *",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[6]||(s[6]=e=>F.form.lounge_type=e),required:""},s[23]||(s[23]=[(0,t.Fv)('<option value="">Select type...</option><option value="cigar_lounge">Cigar Lounge</option><option value="cigar_shop">Cigar Shop</option><option value="cigar_bar">Cigar Bar</option><option value="tobacconist">Tobacconist</option>',5)]),512),[[l.u1,F.form.lounge_type]])])])]),s[26]||(s[26]=(0,t.Lk)("p",{class:"form-note"},"After your listing is approved, you'll be able to add hours, photos, description, and more from your dashboard.",-1)),F.error?((0,t.uX)(),(0,t.CE)("p",C,(0,a.v_)(F.error),1)):(0,t.Q3)("",!0),(0,t.Lk)("button",{type:"submit",class:"btn-primary btn-full",disabled:F.submitting},(0,a.v_)(F.submitting?"Submitting...":"Submit Listing for Review"),9,w)],32)):((0,t.uX)(),(0,t.CE)("div",r,[s[11]||(s[11]=(0,t.Lk)("p",null,"You need a business account to create a listing.",-1)),(0,t.Lk)("div",d,[(0,t.bF)(S,{to:"/business/login",class:"btn-primary"},{default:(0,t.k6)((()=>s[9]||(s[9]=[(0,t.eW)("Log In")]))),_:1}),(0,t.bF)(S,{to:"/business/register",class:"btn-outline"},{default:(0,t.k6)((()=>s[10]||(s[10]=[(0,t.eW)("Create Account")]))),_:1})])]))])])}i(4114);var F=i(7465),E={name:"BusinessCreateListing",data(){return{form:{name:"",address_line1:"",city:"",state:"",zip_code:"",phone:"",lounge_type:""},submitting:!1,submitted:!1,submittedName:"",error:null}},computed:{isLoggedIn(){return!!localStorage.getItem("business_session_token")},token(){return localStorage.getItem("business_session_token")}},methods:{async submitListing(){this.error=null,this.submitting=!0;try{var e=await fetch(F.baseUrl+"api/v1/business/create_listing",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify(this.form)}),s=await e.json();if(e.ok){if(this.submittedName=this.form.name,this.submitted=!0,s.lounge&&s.lounge.id){var i=this;setTimeout((function(){i.$router.push("/business/lounges/"+s.lounge.id+"/edit")}),2e3)}}else this.error=s.errors?s.errors.join(", "):"Failed to submit listing"}catch(t){this.error="Network error. Please try again."}this.submitting=!1}},created(){document.title="Create New Listing - CigarFinder Business"}},S=i(6262);const X=(0,S.A)(E,[["render",_]]);var U=X},9052:function(e,s,i){i.r(s),i.d(s,{default:function(){return K}});var t=i(641),a=i(33),l=i(3751);const o={class:"business-page"},n={key:0,class:"dashboard-container"},r={class:"dashboard-header"},d={class:"dash-nav"},u={key:0,class:"empty-state"},c={class:"start-options"},p={class:"start-option"},h={class:"search-claim"},k={class:"start-option"},g={key:0,class:"search-results"},b={class:"result-info"},m=["onClick"],v={key:1,class:"already-claimed"},L={class:"search-footer"},y={key:1,class:"no-results-box"},f={key:1,class:"lounges-list"},C={class:"lounge-info"},w={key:0,class:"badge-verified"},_={key:1,class:"badge-pending"},F={key:2,class:"badge-featured"},E={class:"lounge-location"},S={class:"lounge-stats"},X={class:"lounge-actions"},U=["onClick"],W={class:"lounge-embed-link"},x={class:"add-another-section"},z={class:"add-another-options"},P={class:"add-option"},T={class:"add-option-search"},V={key:0,class:"search-results"},I={class:"search-count"},M={class:"result-info"},D=["onClick"],B={key:1,class:"already-claimed"},Q={class:"search-footer"},O={key:1,class:"no-results-box"},j={key:2,class:"backlink-section"},N={class:"backlink-actions"},q={key:1,class:"business-container"},J={class:"business-header"},$={key:2,class:"loading"};function A(e,s,i,A,R,H){const Y=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[R.user?((0,t.uX)(),(0,t.CE)("div",n,[(0,t.Lk)("div",r,[s[7]||(s[7]=(0,t.Lk)("h1",null,"Business Dashboard",-1)),(0,t.Lk)("p",null,"Welcome, "+(0,a.v_)(R.user.full_name),1),(0,t.Lk)("button",{onClick:s[0]||(s[0]=(...e)=>H.logout&&H.logout(...e)),class:"btn-logout"},"Logout")]),(0,t.Lk)("div",d,[(0,t.bF)(Y,{to:"/business/dashboard",class:"dash-link active"},{default:(0,t.k6)((()=>s[8]||(s[8]=[(0,t.eW)("Dashboard")]))),_:1}),(0,t.bF)(Y,{to:"/business/subscription",class:"dash-link"},{default:(0,t.k6)((()=>s[9]||(s[9]=[(0,t.eW)("Plans & Billing")]))),_:1}),(0,t.bF)(Y,{to:"/business/support",class:"dash-link"},{default:(0,t.k6)((()=>s[10]||(s[10]=[(0,t.eW)("Support")]))),_:1}),(0,t.bF)(Y,{to:"/business/profile",class:"dash-link"},{default:(0,t.k6)((()=>s[11]||(s[11]=[(0,t.eW)("My Profile")]))),_:1})]),R.lounges.length||R.loading?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",u,[s[22]||(s[22]=(0,t.Lk)("h2",null,"Get Started",-1)),s[23]||(s[23]=(0,t.Lk)("p",null,"Claim your existing business or create a new listing to manage it on CigarFinder.",-1)),(0,t.Lk)("div",c,[(0,t.Lk)("div",p,[s[12]||(s[12]=(0,t.Lk)("h3",null,"Claim Your Business",-1)),s[13]||(s[13]=(0,t.Lk)("p",null,"Already listed on CigarFinder? Search and claim it.",-1)),(0,t.Lk)("div",h,[(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[1]||(s[1]=e=>R.searchQuery=e),placeholder:"Search by business name...",onKeyup:s[2]||(s[2]=(0,l.jR)(((...e)=>H.searchLounges&&H.searchLounges(...e)),["enter"])),class:"search-input"},null,544),[[l.Jo,R.searchQuery]]),(0,t.Lk)("button",{onClick:s[3]||(s[3]=(...e)=>H.searchLounges&&H.searchLounges(...e)),class:"btn-search"},"Search")])]),s[17]||(s[17]=(0,t.Lk)("div",{class:"start-divider"},"or",-1)),(0,t.Lk)("div",k,[s[15]||(s[15]=(0,t.Lk)("h3",null,"Create New Listing",-1)),s[16]||(s[16]=(0,t.Lk)("p",null,"Not listed yet? Add your business to CigarFinder.",-1)),(0,t.bF)(Y,{to:"/business/create-listing",class:"btn-create-primary"},{default:(0,t.k6)((()=>s[14]||(s[14]=[(0,t.eW)("Create a New Listing")]))),_:1})])]),R.searchResults.length?((0,t.uX)(),(0,t.CE)("div",g,[(0,t.Lk)("h3",null,"Found "+(0,a.v_)(R.searchResults.length)+" matches:",1),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(R.searchResults,(e=>((0,t.uX)(),(0,t.CE)("div",{class:"result-card",key:e.id},[(0,t.Lk)("div",b,[(0,t.Lk)("strong",null,(0,a.v_)(e.name),1),(0,t.Lk)("span",null,(0,a.v_)(e.address)+", "+(0,a.v_)(e.city)+", "+(0,a.v_)(e.state),1)]),e.claimed?((0,t.uX)(),(0,t.CE)("span",v,"Already Claimed")):((0,t.uX)(),(0,t.CE)("button",{key:0,onClick:s=>H.startClaim(e),class:"btn-claim"},"Claim This",8,m))])))),128)),(0,t.Lk)("div",L,[(0,t.Lk)("p",null,[s[19]||(s[19]=(0,t.eW)("Don't see your business? ")),(0,t.bF)(Y,{to:"/business/create-listing",class:"create-link"},{default:(0,t.k6)((()=>s[18]||(s[18]=[(0,t.eW)("Create a new listing")]))),_:1})])])])):(0,t.Q3)("",!0),0===R.searchResults.length&&R.searched?((0,t.uX)(),(0,t.CE)("div",y,[s[21]||(s[21]=(0,t.Lk)("p",null,"No businesses found matching your search.",-1)),(0,t.bF)(Y,{to:"/business/create-listing",class:"btn-create-primary"},{default:(0,t.k6)((()=>s[20]||(s[20]=[(0,t.eW)("Create a New Listing Instead")]))),_:1})])):(0,t.Q3)("",!0)])),R.lounges.length?((0,t.uX)(),(0,t.CE)("div",f,[(0,t.Lk)("h2",null,"Your Locations ("+(0,a.v_)(R.lounges.length)+")",1),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(R.lounges,(e=>((0,t.uX)(),(0,t.CE)("div",{class:"lounge-dashboard-card",key:e.id},[(0,t.Lk)("div",C,[(0,t.Lk)("h3",null,[(0,t.eW)((0,a.v_)(e.name)+" ",1),e.claimed?((0,t.uX)(),(0,t.CE)("span",w,"Verified")):e.pending_claim?((0,t.uX)(),(0,t.CE)("span",_,"⚠ Verification Pending")):(0,t.Q3)("",!0),e.featured?((0,t.uX)(),(0,t.CE)("span",F,"Featured")):(0,t.Q3)("",!0)]),(0,t.Lk)("p",E,(0,a.v_)(e.city)+", "+(0,a.v_)(e.state),1),(0,t.Lk)("div",S,[(0,t.Lk)("span",null,"Views: "+(0,a.v_)(e.views_count),1),(0,t.Lk)("span",null,"Reviews: "+(0,a.v_)(e.review_count),1),(0,t.Lk)("span",null,"Rating: "+(0,a.v_)(e.rating||"N/A"),1),(0,t.Lk)("span",null,"Tier: "+(0,a.v_)(e.tier),1)])]),(0,t.Lk)("div",X,[(0,t.bF)(Y,{to:"/business/lounges/"+e.id+"/edit",class:"btn-action"},{default:(0,t.k6)((()=>s[24]||(s[24]=[(0,t.eW)("Edit Listing")]))),_:2},1032,["to"]),(0,t.bF)(Y,{to:"/lounges/"+e.slug,class:"btn-action",target:"_blank"},{default:(0,t.k6)((()=>s[25]||(s[25]=[(0,t.eW)("View Public")]))),_:2},1032,["to"]),(0,t.Lk)("button",{onClick:s=>H.goToSubscription(e.id),class:"btn-action"},"Upgrade",8,U)]),(0,t.Lk)("div",W,[(0,t.bF)(Y,{to:"/business/embed-codes",class:"btn-embed"},{default:(0,t.k6)((()=>s[26]||(s[26]=[(0,t.eW)("Get Embed Codes")]))),_:1})])])))),128)),(0,t.Lk)("div",x,[s[33]||(s[33]=(0,t.Lk)("h3",null,"Add Another Location",-1)),(0,t.Lk)("div",z,[(0,t.Lk)("div",P,[(0,t.Lk)("div",T,[(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[4]||(s[4]=e=>R.searchQuery=e),placeholder:"Search by business name...",onKeyup:s[5]||(s[5]=(0,l.jR)(((...e)=>H.searchLounges&&H.searchLounges(...e)),["enter"])),class:"search-input"},null,544),[[l.Jo,R.searchQuery]]),(0,t.Lk)("button",{onClick:s[6]||(s[6]=(...e)=>H.searchLounges&&H.searchLounges(...e)),class:"btn-search"},"Search & Claim")])]),s[28]||(s[28]=(0,t.Lk)("span",{class:"add-divider"},"or",-1)),(0,t.bF)(Y,{to:"/business/create-listing",class:"btn-create-primary"},{default:(0,t.k6)((()=>s[27]||(s[27]=[(0,t.eW)("Create New Listing")]))),_:1})]),R.searchResults.length?((0,t.uX)(),(0,t.CE)("div",V,[(0,t.Lk)("p",I,"Found "+(0,a.v_)(R.searchResults.length)+" matches:",1),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(R.searchResults,(e=>((0,t.uX)(),(0,t.CE)("div",{class:"result-card",key:e.id},[(0,t.Lk)("div",M,[(0,t.Lk)("strong",null,(0,a.v_)(e.name),1),(0,t.Lk)("span",null,(0,a.v_)(e.city)+", "+(0,a.v_)(e.state),1)]),e.claimed?((0,t.uX)(),(0,t.CE)("span",B,"Already Claimed")):((0,t.uX)(),(0,t.CE)("button",{key:0,onClick:s=>H.startClaim(e),class:"btn-claim"},"Claim This",8,D))])))),128)),(0,t.Lk)("div",Q,[(0,t.Lk)("p",null,[s[30]||(s[30]=(0,t.eW)("Don't see your business? ")),(0,t.bF)(Y,{to:"/business/create-listing",class:"create-link"},{default:(0,t.k6)((()=>s[29]||(s[29]=[(0,t.eW)("Create a new listing")]))),_:1})])])])):(0,t.Q3)("",!0),0===R.searchResults.length&&R.searched?((0,t.uX)(),(0,t.CE)("div",O,[s[32]||(s[32]=(0,t.Lk)("p",null,"No businesses found.",-1)),(0,t.bF)(Y,{to:"/business/create-listing",class:"btn-create-primary"},{default:(0,t.k6)((()=>s[31]||(s[31]=[(0,t.eW)("Create a New Listing")]))),_:1})])):(0,t.Q3)("",!0)])])):(0,t.Q3)("",!0),R.lounges.length?((0,t.uX)(),(0,t.CE)("div",j,[s[35]||(s[35]=(0,t.Lk)("h3",null,"Backlink Status",-1)),s[36]||(s[36]=(0,t.Lk)("p",{class:"backlink-desc"},"Add a CigarFinder link or badge to your website to get premium listing features for free.",-1)),(0,t.Lk)("div",N,[(0,t.bF)(Y,{to:"/business/embed-codes",class:"btn-action"},{default:(0,t.k6)((()=>s[34]||(s[34]=[(0,t.eW)("Get Embed Codes")]))),_:1})])])):(0,t.Q3)("",!0)])):R.loading?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",q,[(0,t.Lk)("div",J,[s[38]||(s[38]=(0,t.Lk)("h1",null,"Business Dashboard",-1)),s[39]||(s[39]=(0,t.Lk)("p",null,"Please log in to manage your listings.",-1)),(0,t.bF)(Y,{to:"/business/login",class:"btn-submit",style:{display:"inline-block","margin-top":"16px","text-decoration":"none"}},{default:(0,t.k6)((()=>s[37]||(s[37]=[(0,t.eW)("Log In")]))),_:1})])])),R.loading?((0,t.uX)(),(0,t.CE)("div",$,s[40]||(s[40]=[(0,t.Lk)("p",null,"Loading dashboard...",-1)]))):(0,t.Q3)("",!0)])}i(4114);var R=i(7465),H={name:"BusinessDashboard",data(){return{user:null,lounges:[],loading:!0,searchQuery:"",searchResults:[],searched:!1}},methods:{async fetchDashboard(){const e=localStorage.getItem("business_session_token");if(e)try{const s=await fetch(`${R.baseUrl}api/v1/business/dashboard`,{headers:{"Session-Token":e}});if(!s.ok)return localStorage.removeItem("business_session_token"),localStorage.removeItem("business_user"),void(this.loading=!1);const i=await s.json();this.user=i.owner,this.lounges=i.lounges||[]}catch(s){console.error("Dashboard error:",s)}finally{this.loading=!1}else this.loading=!1},async searchLounges(){if(this.searchQuery.trim()){this.searched=!0;try{const e=await fetch(`${R.baseUrl}api/v1/lounges?q=${encodeURIComponent(this.searchQuery)}&per_page=10`),s=await e.json();this.searchResults=s.lounges||[]}catch(e){console.error("Search error:",e)}}},goToSubscription(e){localStorage.setItem("business_active_lounge_id",e),this.$router.push("/business/subscription")},startClaim(e){this.$router.push("/business/claim/"+e.id)},logout(){const e=localStorage.getItem("business_session_token");e&&fetch(`${R.baseUrl}api/v1/business/logout`,{method:"DELETE",headers:{"Session-Token":e}}).catch((()=>{})),localStorage.removeItem("business_session_token"),localStorage.removeItem("business_user"),this.user=null,this.lounges=[],this.$router.push("/business/login")}},created(){document.title="Business Dashboard - CigarFinder",this.fetchDashboard()}},Y=i(6262);const G=(0,Y.A)(H,[["render",A],["__scopeId","data-v-818568fc"]]);var K=G},966:function(e,s,i){i.r(s),i.d(s,{default:function(){return si}});var t=i(641),a=i(33),l=i(3751);const o={class:"biz-page"},n={key:0,class:"edit-container"},r={class:"edit-header"},d={key:0,class:"save-bar"},u=["disabled"],c={key:1,class:"pending-banner"},p={key:2,class:"edit-success"},h={key:3,class:"biz-error"},k={class:"edit-section"},g={class:"toggle-indicator"},b={key:0,class:"expand-hint"},m={class:"section-body"},v={class:"field-row"},L={class:"biz-field full"},y=["value"],f={class:"field-row"},C={class:"biz-field"},w={class:"biz-field"},_={class:"field-row three"},F={class:"biz-field"},E={class:"biz-field small"},S={class:"biz-field small"},X={class:"field-row"},U={class:"biz-field"},W={class:"biz-field"},x={class:"field-row"},z={class:"biz-field full"},P={class:"biz-field full"},T={class:"edit-section"},V={class:"toggle-indicator"},I={key:0,class:"expand-hint"},M={class:"section-body"},D={class:"hours-grid"},B={class:"day-label"},Q={class:"closed-toggle"},O=["onUpdate:modelValue"],j=["onUpdate:modelValue"],N=["onUpdate:modelValue"],q={key:1,class:"closed-label"},J={class:"edit-section"},$={class:"toggle-indicator"},A={key:0,class:"expand-hint"},R={class:"section-body"},H={class:"biz-field full"},Y={class:"group-label"},G={key:0,class:"lock-badge"},K={class:"check-item"},Z=["disabled"],ee={class:"check-item"},se=["disabled"],ie={class:"check-item"},te=["disabled"],ae={key:0,class:"lock-badge"},le={key:0,class:"selected-tags"},oe=["onClick"],ne={key:0,class:"multiselect-placeholder"},re={key:1,class:"multiselect-placeholder"},de={class:"multiselect-dropdown"},ue=["value","disabled"],ce={class:"edit-section"},pe={class:"toggle-indicator"},he={key:0,class:"expand-hint"},ke={class:"section-body"},ge={class:"subsection"},be={class:"toggle-grid"},me={class:"toggle-item"},ve={class:"toggle-item"},Le={class:"toggle-item"},ye={class:"toggle-item"},fe={class:"toggle-item"},Ce={class:"toggle-item"},we={class:"toggle-item"},_e={class:"subsection"},Fe={class:"toggle-grid"},Ee={class:"toggle-item"},Se={class:"toggle-item"},Xe={class:"toggle-item"},Ue={class:"subsection"},We={class:"field-row"},xe={class:"biz-field"},ze=["value"],Pe={class:"biz-field"},Te=["value"],Ve={class:"toggle-item"},Ie={class:"subsection"},Me={class:"toggle-item"},De={key:0,class:"field-row"},Be={class:"biz-field"},Qe={class:"subsection"},Oe={class:"field-row"},je={class:"biz-field"},Ne=["value"],qe={class:"biz-field"},Je=["value"],$e={class:"biz-field full"},Ae={class:"tag-select"},Re=["value"],He={class:"group-label"},Ye={key:0,class:"lock-badge"},Ge={class:"toggle-item"},Ke=["disabled"],Ze={key:0,class:"biz-field full"},es=["disabled"],ss={class:"group-label"},is={key:0,class:"lock-badge"},ts={class:"toggle-item"},as=["disabled"],ls={key:0,class:"toggle-item"},os=["disabled"],ns={class:"toggle-item"},rs=["disabled"],ds={class:"edit-section"},us={class:"section-title"},cs={class:"toggle-indicator"},ps={key:0,class:"expand-hint"},hs={class:"section-body"},ks={key:0,class:"photos-grid"},gs=["src","alt"],bs=["onClick"],ms={key:1,class:"biz-field"},vs={key:2,class:"field-hint"},Ls={class:"section-title"},ys={key:0,class:"lock-badge"},fs={class:"toggle-indicator"},Cs={key:0,class:"expand-hint"},ws={class:"section-body"},_s={class:"biz-field"},Fs=["disabled"],Es={class:"biz-field"},Ss=["disabled"],Xs={class:"biz-field"},Us=["disabled"],Ws={class:"biz-field"},xs=["disabled"],zs={class:"biz-field"},Ps=["disabled"],Ts={class:"biz-field"},Vs=["disabled"],Is={class:"section-title"},Ms={key:0,class:"lock-badge"},Ds={class:"toggle-indicator"},Bs={key:0,class:"expand-hint"},Qs={class:"section-body"},Os=["onClick"],js={class:"field-row"},Ns={class:"biz-field"},qs={class:"biz-field"},Js={class:"biz-field full"},$s={class:"save-section"},As=["disabled"],Rs={key:1,class:"edit-loading"},Hs={key:2,class:"edit-loading"};function Ys(e,s,i,Ys,Gs,Ks){const Zs=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[Gs.lounge?((0,t.uX)(),(0,t.CE)("div",n,[(0,t.Lk)("div",r,[(0,t.Lk)("h1",null,"Edit Listing: "+(0,a.v_)(Gs.lounge.name),1),(0,t.bF)(Zs,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[58]||(s[58]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),Gs.hasChanges?((0,t.uX)(),(0,t.CE)("div",d,[s[59]||(s[59]=(0,t.Lk)("span",null,"You have unsaved changes",-1)),(0,t.Lk)("button",{class:"biz-btn",onClick:s[0]||(s[0]=(...e)=>Ks.saveListing&&Ks.saveListing(...e)),disabled:Gs.saving},(0,a.v_)(Gs.saving?"Saving...":"Save Changes"),9,u)])):(0,t.Q3)("",!0),Gs.lounge&&!Gs.lounge.claimed?((0,t.uX)(),(0,t.CE)("div",c,[s[61]||(s[61]=(0,t.Lk)("strong",null,"⚠ Verification Pending",-1)),s[62]||(s[62]=(0,t.Lk)("p",null,"You can edit your listing now. Your changes will go live once verification is complete.",-1)),(0,t.bF)(Zs,{to:"/business/claim/"+Gs.lounge.id},{default:(0,t.k6)((()=>s[60]||(s[60]=[(0,t.eW)("Complete Verification →")]))),_:1},8,["to"])])):(0,t.Q3)("",!0),Gs.saveMsg?((0,t.uX)(),(0,t.CE)("p",p,(0,a.v_)(Gs.saveMsg),1)):(0,t.Q3)("",!0),Gs.error?((0,t.uX)(),(0,t.CE)("p",h,(0,a.v_)(Gs.error),1)):(0,t.Q3)("",!0),(0,t.Lk)("div",k,[(0,t.Lk)("h2",{onClick:s[1]||(s[1]=e=>Ks.toggleSection("basic")),class:"section-toggle"},[s[64]||(s[64]=(0,t.Lk)("span",{class:"section-title"},"Basic Information",-1)),(0,t.Lk)("span",g,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.basic}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[63]||(s[63]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.basic?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",b,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",m,[(0,t.Lk)("div",v,[(0,t.Lk)("div",L,[s[65]||(s[65]=(0,t.Lk)("label",null,"Business Name",-1)),(0,t.Lk)("input",{type:"text",value:Gs.lounge.name,disabled:"",class:"disabled-input"},null,8,y),s[66]||(s[66]=(0,t.Lk)("span",{class:"field-hint"},"Contact support to change your business name",-1))])]),(0,t.Lk)("div",f,[(0,t.Lk)("div",C,[s[67]||(s[67]=(0,t.Lk)("label",null,"Address",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[2]||(s[2]=e=>Gs.form.address_line1=e),placeholder:"Street address"},null,512),[[l.Jo,Gs.form.address_line1]])]),(0,t.Lk)("div",w,[s[68]||(s[68]=(0,t.Lk)("label",null,"Suite / Unit",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[3]||(s[3]=e=>Gs.form.address_line2=e),placeholder:"Suite, unit, floor"},null,512),[[l.Jo,Gs.form.address_line2]])])]),(0,t.Lk)("div",_,[(0,t.Lk)("div",F,[s[69]||(s[69]=(0,t.Lk)("label",null,"City",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[4]||(s[4]=e=>Gs.form.city=e)},null,512),[[l.Jo,Gs.form.city]])]),(0,t.Lk)("div",E,[s[70]||(s[70]=(0,t.Lk)("label",null,"State",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[5]||(s[5]=e=>Gs.form.state=e),maxlength:"2",placeholder:"FL"},null,512),[[l.Jo,Gs.form.state]])]),(0,t.Lk)("div",S,[s[71]||(s[71]=(0,t.Lk)("label",null,"Zip Code",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[6]||(s[6]=e=>Gs.form.zip_code=e),maxlength:"10"},null,512),[[l.Jo,Gs.form.zip_code]])])]),(0,t.Lk)("div",X,[(0,t.Lk)("div",U,[s[72]||(s[72]=(0,t.Lk)("label",null,"Phone",-1)),(0,t.bo)((0,t.Lk)("input",{type:"tel","onUpdate:modelValue":s[7]||(s[7]=e=>Gs.form.phone=e),placeholder:"+1 (555) 123-4567"},null,512),[[l.Jo,Gs.form.phone]])]),(0,t.Lk)("div",W,[s[73]||(s[73]=(0,t.Lk)("label",null,"Email",-1)),(0,t.bo)((0,t.Lk)("input",{type:"email","onUpdate:modelValue":s[8]||(s[8]=e=>Gs.form.email=e),placeholder:"info@yourbusiness.com"},null,512),[[l.Jo,Gs.form.email]])])]),(0,t.Lk)("div",x,[(0,t.Lk)("div",z,[s[74]||(s[74]=(0,t.Lk)("label",null,"Website",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[9]||(s[9]=e=>Gs.form.website=e),placeholder:"https://yourbusiness.com"},null,512),[[l.Jo,Gs.form.website]])])]),(0,t.Lk)("div",P,[s[76]||(s[76]=(0,t.Lk)("label",null,"Business Type",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[10]||(s[10]=e=>Gs.form.lounge_type=e)},s[75]||(s[75]=[(0,t.Lk)("option",{value:"cigar_lounge"},"Cigar Lounge",-1),(0,t.Lk)("option",{value:"cigar_shop"},"Cigar Shop",-1),(0,t.Lk)("option",{value:"cigar_bar"},"Cigar Bar",-1),(0,t.Lk)("option",{value:"tobacconist"},"Tobacconist",-1)]),512),[[l.u1,Gs.form.lounge_type]])])],512),[[l.aG,Gs.sections.basic]])]),(0,t.Lk)("div",T,[(0,t.Lk)("h2",{onClick:s[11]||(s[11]=e=>Ks.toggleSection("hours")),class:"section-toggle"},[s[78]||(s[78]=(0,t.Lk)("span",{class:"section-title"},"Business Hours",-1)),(0,t.Lk)("span",V,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.hours}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[77]||(s[77]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.hours?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",I,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",M,[s[81]||(s[81]=(0,t.Lk)("p",{class:"hours-helper"},"Set hours for each day your business is open",-1)),(0,t.Lk)("div",D,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.dayOrder,(e=>((0,t.uX)(),(0,t.CE)("div",{key:e,class:(0,a.C4)(["hours-row",{"row-closed":Gs.hoursClosed[e]}])},[(0,t.Lk)("label",B,(0,a.v_)(Gs.dayNames[e]),1),(0,t.Lk)("label",Q,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s=>Gs.hoursClosed[e]=s},null,8,O),[[l.lH,Gs.hoursClosed[e]]]),s[79]||(s[79]=(0,t.eW)(" Closed "))]),Gs.hoursClosed[e]?((0,t.uX)(),(0,t.CE)("span",q,"Not open this day")):((0,t.uX)(),(0,t.CE)(t.FK,{key:0},[(0,t.bo)((0,t.Lk)("input",{type:"time","onUpdate:modelValue":s=>Gs.hoursOpen[e]=s,class:"time-input"},null,8,j),[[l.Jo,Gs.hoursOpen[e]]]),s[80]||(s[80]=(0,t.Lk)("span",{class:"time-sep"},"to",-1)),(0,t.bo)((0,t.Lk)("input",{type:"time","onUpdate:modelValue":s=>Gs.hoursClose[e]=s,class:"time-input"},null,8,N),[[l.Jo,Gs.hoursClose[e]]])],64))],2)))),128))])],512),[[l.aG,Gs.sections.hours]])]),(0,t.Lk)("div",J,[(0,t.Lk)("h2",{onClick:s[12]||(s[12]=e=>Ks.toggleSection("about")),class:"section-toggle"},[s[83]||(s[83]=(0,t.Lk)("span",{class:"section-title"},"About Your Business",-1)),(0,t.Lk)("span",$,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.about}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[82]||(s[82]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.about?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",A,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",R,[(0,t.Lk)("div",H,[s[84]||(s[84]=(0,t.Lk)("label",null,"Description",-1)),(0,t.bo)((0,t.Lk)("textarea",{"onUpdate:modelValue":s[13]||(s[13]=e=>Gs.form.description=e),rows:"5",placeholder:"Tell customers about your business, what makes it special, your history..."},null,512),[[l.Jo,Gs.form.description]])]),(0,t.Lk)("div",{class:(0,a.C4)(["checkbox-group",{locked:!Ks.canEditIdentity}])},[(0,t.Lk)("label",Y,[s[85]||(s[85]=(0,t.eW)("Business Identity ")),Ks.canEditIdentity?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",G,"Featured Only"))]),(0,t.Lk)("label",K,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[14]||(s[14]=e=>Gs.identityForm.women_owned=e),disabled:!Ks.canEditIdentity},null,8,Z),[[l.lH,Gs.identityForm.women_owned]]),s[86]||(s[86]=(0,t.eW)(" Women Owned & Operated"))]),(0,t.Lk)("label",ee,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[15]||(s[15]=e=>Gs.identityForm.minority_owned=e),disabled:!Ks.canEditIdentity},null,8,se),[[l.lH,Gs.identityForm.minority_owned]]),s[87]||(s[87]=(0,t.eW)(" Minority Owned & Operated"))]),(0,t.Lk)("label",ie,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[16]||(s[16]=e=>Gs.identityForm.veteran_owned=e),disabled:!Ks.canEditIdentity},null,8,te),[[l.lH,Gs.identityForm.veteran_owned]]),s[88]||(s[88]=(0,t.eW)(" Veteran Owned & Operated"))])],2),(0,t.Lk)("div",{class:(0,a.C4)(["biz-field full",{locked:!Ks.canEditIdentity}])},[(0,t.Lk)("label",null,[s[89]||(s[89]=(0,t.eW)("Languages Spoken ")),Ks.canEditIdentity?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",ae,"Featured Only"))]),(0,t.Lk)("div",{class:(0,a.C4)(["language-multiselect",{disabled:!Ks.canEditIdentity}])},[Gs.identityForm.languages.length?((0,t.uX)(),(0,t.CE)("div",le,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.identityForm.languages,(e=>((0,t.uX)(),(0,t.CE)("span",{class:"lang-tag",key:e},[(0,t.eW)((0,a.v_)(e)+" ",1),Ks.canEditIdentity?((0,t.uX)(),(0,t.CE)("button",{key:0,type:"button",class:"tag-remove",onClick:s=>Ks.removeLanguage(e)},"×",8,oe)):(0,t.Q3)("",!0)])))),128))])):(0,t.Q3)("",!0),(0,t.Lk)("div",{class:(0,a.C4)(["multiselect-trigger",{active:Gs.languageDropdownOpen}]),onClick:s[17]||(s[17]=(...e)=>Ks.toggleLanguageDropdown&&Ks.toggleLanguageDropdown(...e))},[Gs.identityForm.languages.length?((0,t.uX)(),(0,t.CE)("span",re,(0,a.v_)(Gs.identityForm.languages.length)+" selected",1)):((0,t.uX)(),(0,t.CE)("span",ne,"Select languages...")),((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.languageDropdownOpen}]),width:"14",height:"14",viewBox:"0 0 16 16",fill:"none"},s[90]||(s[90]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2))],2),(0,t.bo)((0,t.Lk)("div",de,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.languageOptions,(e=>((0,t.uX)(),(0,t.CE)("label",{key:e,class:(0,a.C4)(["dropdown-check-item",{selected:Gs.identityForm.languages.includes(e)}])},[(0,t.bo)((0,t.Lk)("input",{type:"checkbox",value:e,"onUpdate:modelValue":s[18]||(s[18]=e=>Gs.identityForm.languages=e),disabled:!Ks.canEditIdentity},null,8,ue),[[l.lH,Gs.identityForm.languages]]),(0,t.Lk)("span",null,(0,a.v_)(e),1)],2)))),128))],512),[[l.aG,Gs.languageDropdownOpen]])],2)],2)],512),[[l.aG,Gs.sections.about]])]),(0,t.Lk)("div",ce,[(0,t.Lk)("h2",{onClick:s[19]||(s[19]=e=>Ks.toggleSection("features")),class:"section-toggle"},[s[92]||(s[92]=(0,t.Lk)("span",{class:"section-title"},"Features & Amenities",-1)),(0,t.Lk)("span",pe,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.features}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[91]||(s[91]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.features?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",he,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",ke,[(0,t.Lk)("div",ge,[s[100]||(s[100]=(0,t.Lk)("label",{class:"group-label"},"Lounge Features",-1)),(0,t.Lk)("div",be,[(0,t.Lk)("label",me,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[20]||(s[20]=e=>Gs.amenitiesForm.lounge_area=e)},null,512),[[l.lH,Gs.amenitiesForm.lounge_area]]),s[93]||(s[93]=(0,t.eW)(" Lounge Area"))]),(0,t.Lk)("label",ve,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[21]||(s[21]=e=>Gs.amenitiesForm.wifi=e)},null,512),[[l.lH,Gs.amenitiesForm.wifi]]),s[94]||(s[94]=(0,t.eW)(" Wi-Fi"))]),(0,t.Lk)("label",Le,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[22]||(s[22]=e=>Gs.amenitiesForm.tv=e)},null,512),[[l.lH,Gs.amenitiesForm.tv]]),s[95]||(s[95]=(0,t.eW)(" TV"))]),(0,t.Lk)("label",ye,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[23]||(s[23]=e=>Gs.amenitiesForm.parking=e)},null,512),[[l.lH,Gs.amenitiesForm.parking]]),s[96]||(s[96]=(0,t.eW)(" Parking"))]),(0,t.Lk)("label",fe,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[24]||(s[24]=e=>Gs.amenitiesForm.outdoor=e)},null,512),[[l.lH,Gs.amenitiesForm.outdoor]]),s[97]||(s[97]=(0,t.eW)(" Outdoor/Patio"))]),(0,t.Lk)("label",Ce,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[25]||(s[25]=e=>Gs.amenitiesForm.events=e)},null,512),[[l.lH,Gs.amenitiesForm.events]]),s[98]||(s[98]=(0,t.eW)(" Hosts Events"))]),(0,t.Lk)("label",we,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[26]||(s[26]=e=>Gs.amenitiesForm.private_lockers=e)},null,512),[[l.lH,Gs.amenitiesForm.private_lockers]]),s[99]||(s[99]=(0,t.eW)(" Private Lockers"))])])]),(0,t.Lk)("div",_e,[s[104]||(s[104]=(0,t.Lk)("label",{class:"group-label"},"Cigar Features",-1)),(0,t.Lk)("div",Fe,[(0,t.Lk)("label",Ee,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[27]||(s[27]=e=>Gs.featuresForm.walk_in_humidor=e)},null,512),[[l.lH,Gs.featuresForm.walk_in_humidor]]),s[101]||(s[101]=(0,t.eW)(" Walk-in Humidor"))]),(0,t.Lk)("label",Se,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[28]||(s[28]=e=>Gs.featuresForm.smoke_inside=e)},null,512),[[l.lH,Gs.featuresForm.smoke_inside]]),s[102]||(s[102]=(0,t.eW)(" Smoke Inside"))]),(0,t.Lk)("label",Xe,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[29]||(s[29]=e=>Gs.featuresForm.handroll_service=e)},null,512),[[l.lH,Gs.featuresForm.handroll_service]]),s[103]||(s[103]=(0,t.eW)(" Handroll / Rolling Service"))])])]),(0,t.Lk)("div",Ue,[s[110]||(s[110]=(0,t.Lk)("label",{class:"group-label"},"Food & Drink",-1)),(0,t.Lk)("div",We,[(0,t.Lk)("div",xe,[s[106]||(s[106]=(0,t.Lk)("label",null,"Bar Type",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[30]||(s[30]=e=>Gs.featuresForm.bar_type=e)},[s[105]||(s[105]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.options.bar_types,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,a.v_)(e.label),9,ze)))),128))],512),[[l.u1,Gs.featuresForm.bar_type]])]),(0,t.Lk)("div",Pe,[s[108]||(s[108]=(0,t.Lk)("label",null,"Food",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[31]||(s[31]=e=>Gs.featuresForm.food_type=e)},[s[107]||(s[107]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.options.food_types,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,a.v_)(e.label),9,Te)))),128))],512),[[l.u1,Gs.featuresForm.food_type]])])]),(0,t.Lk)("label",Ve,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[32]||(s[32]=e=>Gs.featuresForm.gambling_gaming=e)},null,512),[[l.lH,Gs.featuresForm.gambling_gaming]]),s[109]||(s[109]=(0,t.eW)(" Gambling / Gaming"))])]),(0,t.Lk)("div",Ie,[s[113]||(s[113]=(0,t.Lk)("label",{class:"group-label"},"Cigar Policy",-1)),(0,t.Lk)("label",Me,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[33]||(s[33]=e=>Gs.featuresForm.allows_outside_cigars=e)},null,512),[[l.lH,Gs.featuresForm.allows_outside_cigars]]),s[111]||(s[111]=(0,t.eW)(" Allow Outside Cigars"))]),Gs.featuresForm.allows_outside_cigars?((0,t.uX)(),(0,t.CE)("div",De,[(0,t.Lk)("div",Be,[s[112]||(s[112]=(0,t.Lk)("label",null,"Cutting Fee",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[34]||(s[34]=e=>Gs.featuresForm.cutting_fee=e),placeholder:"e.g. .00 or Free"},null,512),[[l.Jo,Gs.featuresForm.cutting_fee]])])])):(0,t.Q3)("",!0)]),(0,t.Lk)("div",Qe,[s[119]||(s[119]=(0,t.Lk)("label",{class:"group-label"},"Atmosphere",-1)),(0,t.Lk)("div",Oe,[(0,t.Lk)("div",je,[s[115]||(s[115]=(0,t.Lk)("label",null,"Located In",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[35]||(s[35]=e=>Gs.featuresForm.located_in=e)},[s[114]||(s[114]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.options.located_in,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,a.v_)(e.label),9,Ne)))),128))],512),[[l.u1,Gs.featuresForm.located_in]])]),(0,t.Lk)("div",qe,[s[117]||(s[117]=(0,t.Lk)("label",null,"Dress Code",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[36]||(s[36]=e=>Gs.featuresForm.dress_code=e)},[s[116]||(s[116]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.options.dress_codes,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,a.v_)(e.label),9,Je)))),128))],512),[[l.u1,Gs.featuresForm.dress_code]])])]),(0,t.Lk)("div",$e,[s[118]||(s[118]=(0,t.Lk)("label",null,"Atmosphere (select all that apply)",-1)),(0,t.Lk)("div",Ae,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.options.atmospheres,(e=>((0,t.uX)(),(0,t.CE)("label",{key:e.value,class:"check-item inline"},[(0,t.bo)((0,t.Lk)("input",{type:"checkbox",value:e.value,"onUpdate:modelValue":s[37]||(s[37]=e=>Gs.featuresForm.atmosphere=e)},null,8,Re),[[l.lH,Gs.featuresForm.atmosphere]]),(0,t.eW)(" "+(0,a.v_)(e.label),1)])))),128))])])]),(0,t.Lk)("div",{class:(0,a.C4)(["subsection",{locked:!Ks.isFeatured}])},[(0,t.Lk)("label",He,[s[120]||(s[120]=(0,t.eW)("Entertainment ")),Ks.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Ye,"Featured Only"))]),(0,t.Lk)("label",Ge,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[38]||(s[38]=e=>Gs.featuresForm.live_entertainment=e),disabled:!Ks.isFeatured},null,8,Ke),[[l.lH,Gs.featuresForm.live_entertainment]]),s[121]||(s[121]=(0,t.eW)(" Live Entertainment"))]),Gs.featuresForm.live_entertainment?((0,t.uX)(),(0,t.CE)("div",Ze,[s[122]||(s[122]=(0,t.Lk)("label",null,"Entertainment Schedule URL",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[39]||(s[39]=e=>Gs.featuresForm.entertainment_schedule_url=e),placeholder:"https://yourbusiness.com/events",disabled:!Ks.isFeatured},null,8,es),[[l.Jo,Gs.featuresForm.entertainment_schedule_url]])])):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,a.C4)(["subsection",{locked:!Ks.isFeatured}])},[(0,t.Lk)("label",ss,[s[123]||(s[123]=(0,t.eW)("Membership ")),Ks.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",is,"Featured Only"))]),(0,t.Lk)("label",ts,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[40]||(s[40]=e=>Gs.featuresForm.private_membership=e),disabled:!Ks.isFeatured},null,8,as),[[l.lH,Gs.featuresForm.private_membership]]),s[124]||(s[124]=(0,t.eW)(" Private Lounge Membership"))]),Gs.featuresForm.private_membership?((0,t.uX)(),(0,t.CE)("label",ls,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[41]||(s[41]=e=>Gs.featuresForm.twenty_four_hour_access=e),disabled:!Ks.isFeatured},null,8,os),[[l.lH,Gs.featuresForm.twenty_four_hour_access]]),s[125]||(s[125]=(0,t.eW)(" 24 Hour Access"))])):(0,t.Q3)("",!0),(0,t.Lk)("label",ns,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[42]||(s[42]=e=>Gs.featuresForm.work_desk=e),disabled:!Ks.isFeatured},null,8,rs),[[l.lH,Gs.featuresForm.work_desk]]),s[126]||(s[126]=(0,t.eW)(" Work Desk / Computer Area"))])],2)],512),[[l.aG,Gs.sections.features]])]),(0,t.Lk)("div",ds,[(0,t.Lk)("h2",{onClick:s[43]||(s[43]=e=>Ks.toggleSection("photos")),class:"section-toggle"},[(0,t.Lk)("span",us,"Photos ("+(0,a.v_)(Gs.lounge.photos?Gs.lounge.photos.length:0)+" / "+(0,a.v_)(Gs.lounge.max_photos||1)+")",1),(0,t.Lk)("span",cs,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.photos}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[127]||(s[127]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.photos?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",ps,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",hs,[Gs.lounge.photos&&Gs.lounge.photos.length?((0,t.uX)(),(0,t.CE)("div",ks,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.lounge.photos,(e=>((0,t.uX)(),(0,t.CE)("div",{key:e.id,class:"photo-thumb"},[(0,t.Lk)("img",{src:e.url,alt:e.caption||"Photo"},null,8,gs),(0,t.Lk)("button",{class:"photo-delete",onClick:s=>Ks.deletePhoto(e.id)},"×",8,bs)])))),128))])):(0,t.Q3)("",!0),(Gs.lounge.photos||[]).length<(Gs.lounge.max_photos||1)?((0,t.uX)(),(0,t.CE)("div",ms,[s[128]||(s[128]=(0,t.Lk)("label",null,"Upload Photo",-1)),(0,t.Lk)("input",{type:"file",onChange:s[44]||(s[44]=(...e)=>Ks.uploadPhoto&&Ks.uploadPhoto(...e)),accept:"image/*",ref:"photoInput"},null,544)])):((0,t.uX)(),(0,t.CE)("p",vs,[s[130]||(s[130]=(0,t.eW)("Maximum photos reached for your tier. ")),(0,t.bF)(Zs,{to:"/business/subscription"},{default:(0,t.k6)((()=>s[129]||(s[129]=[(0,t.eW)("Upgrade for more →")]))),_:1})]))],512),[[l.aG,Gs.sections.photos]])]),(0,t.Lk)("div",{class:(0,a.C4)(["edit-section",{locked:!Ks.isFeatured}])},[(0,t.Lk)("h2",{onClick:s[45]||(s[45]=e=>Ks.toggleSection("social")),class:"section-toggle"},[(0,t.Lk)("span",Ls,[s[131]||(s[131]=(0,t.eW)("Social Profiles ")),Ks.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",ys,"Featured Only"))]),(0,t.Lk)("span",fs,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.social}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[132]||(s[132]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.social?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Cs,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",ws,[(0,t.Lk)("div",_s,[s[133]||(s[133]=(0,t.Lk)("label",null,"Facebook",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[46]||(s[46]=e=>Gs.socialForm.facebook=e),placeholder:"https://facebook.com/yourbusiness",disabled:!Ks.isFeatured},null,8,Fs),[[l.Jo,Gs.socialForm.facebook]])]),(0,t.Lk)("div",Es,[s[134]||(s[134]=(0,t.Lk)("label",null,"Instagram",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[47]||(s[47]=e=>Gs.socialForm.instagram=e),placeholder:"https://instagram.com/yourbusiness",disabled:!Ks.isFeatured},null,8,Ss),[[l.Jo,Gs.socialForm.instagram]])]),(0,t.Lk)("div",Xs,[s[135]||(s[135]=(0,t.Lk)("label",null,"TikTok",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[48]||(s[48]=e=>Gs.socialForm.tiktok=e),placeholder:"https://tiktok.com/@yourbusiness",disabled:!Ks.isFeatured},null,8,Us),[[l.Jo,Gs.socialForm.tiktok]])]),(0,t.Lk)("div",Ws,[s[136]||(s[136]=(0,t.Lk)("label",null,"YouTube",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[49]||(s[49]=e=>Gs.socialForm.youtube=e),placeholder:"https://youtube.com/@yourbusiness",disabled:!Ks.isFeatured},null,8,xs),[[l.Jo,Gs.socialForm.youtube]])]),(0,t.Lk)("div",zs,[s[137]||(s[137]=(0,t.Lk)("label",null,"LinkedIn",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[50]||(s[50]=e=>Gs.socialForm.linkedin=e),placeholder:"https://linkedin.com/company/yourbusiness",disabled:!Ks.isFeatured},null,8,Ps),[[l.Jo,Gs.socialForm.linkedin]])]),(0,t.Lk)("div",Ts,[s[138]||(s[138]=(0,t.Lk)("label",null,"Twitter / X",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[51]||(s[51]=e=>Gs.socialForm.twitter=e),placeholder:"https://x.com/yourbusiness",disabled:!Ks.isFeatured},null,8,Vs),[[l.Jo,Gs.socialForm.twitter]])])],512),[[l.aG,Gs.sections.social]])],2),(0,t.Lk)("div",{class:(0,a.C4)(["edit-section",{locked:!Ks.isFeatured}])},[(0,t.Lk)("h2",{onClick:s[52]||(s[52]=e=>Ks.toggleSection("events")),class:"section-toggle"},[(0,t.Lk)("span",Is,[s[139]||(s[139]=(0,t.eW)("Events ")),Ks.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Ms,"Featured Only"))]),(0,t.Lk)("span",Ds,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,a.C4)(["chevron-icon",{open:Gs.sections.events}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[140]||(s[140]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),Gs.sections.events?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Bs,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",Qs,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(Gs.lounge.events,(e=>((0,t.uX)(),(0,t.CE)("div",{key:e.id,class:"event-item"},[(0,t.Lk)("strong",null,(0,a.v_)(e.title),1),(0,t.eW)(" — "+(0,a.v_)(new Date(e.event_date).toLocaleDateString())+" ",1),(0,t.Lk)("button",{class:"small-delete",onClick:s=>Ks.deleteEvent(e.id)},"Remove",8,Os)])))),128)),s[144]||(s[144]=(0,t.Lk)("h3",{class:"mt-16"},"Add Event",-1)),(0,t.Lk)("div",js,[(0,t.Lk)("div",Ns,[s[141]||(s[141]=(0,t.Lk)("label",null,"Title",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[53]||(s[53]=e=>Gs.newEvent.title=e),placeholder:"Cigar & Whiskey Night"},null,512),[[l.Jo,Gs.newEvent.title]])]),(0,t.Lk)("div",qs,[s[142]||(s[142]=(0,t.Lk)("label",null,"Date",-1)),(0,t.bo)((0,t.Lk)("input",{type:"datetime-local","onUpdate:modelValue":s[54]||(s[54]=e=>Gs.newEvent.event_date=e)},null,512),[[l.Jo,Gs.newEvent.event_date]])])]),(0,t.Lk)("div",Js,[s[143]||(s[143]=(0,t.Lk)("label",null,"Description",-1)),(0,t.bo)((0,t.Lk)("textarea",{"onUpdate:modelValue":s[55]||(s[55]=e=>Gs.newEvent.description=e),rows:"2",placeholder:"Details about the event..."},null,512),[[l.Jo,Gs.newEvent.description]])]),(0,t.Lk)("button",{class:"biz-btn-sm",onClick:s[56]||(s[56]=(...e)=>Ks.addEvent&&Ks.addEvent(...e))},"Add Event")],512),[[l.aG,Gs.sections.events&&Ks.isFeatured]])],2),(0,t.Lk)("div",$s,[(0,t.Lk)("button",{class:"biz-btn",onClick:s[57]||(s[57]=(...e)=>Ks.saveListing&&Ks.saveListing(...e)),disabled:Gs.saving},(0,a.v_)(Gs.saving?"Saving...":"Save All Changes"),9,As),(0,t.bF)(Zs,{to:"/lounges/"+Gs.lounge.slug,class:"view-link",target:"_blank"},{default:(0,t.k6)((()=>s[145]||(s[145]=[(0,t.eW)("View Public Listing →")]))),_:1},8,["to"])])])):Gs.loading?((0,t.uX)(),(0,t.CE)("div",Rs,s[146]||(s[146]=[(0,t.Lk)("p",null,"Loading listing...",-1)]))):((0,t.uX)(),(0,t.CE)("div",Hs,s[147]||(s[147]=[(0,t.Lk)("p",null,"Listing not found or you don't have access.",-1)])))])}i(4114),i(8992),i(4520),i(3949);var Gs=i(7465),Ks={name:"BusinessEditListing",data(){return{lounge:null,loading:!0,saving:!1,error:null,saveMsg:null,hasChanges:!1,initialLoaded:!1,languageDropdownOpen:!1,options:{bar_types:[],food_types:[],located_in:[],dress_codes:[],atmospheres:[]},languageOptions:[],sections:{basic:!0,hours:!0,about:!0,features:!1,photos:!1,social:!1,events:!1},dayOrder:["mon","tue","wed","thu","fri","sat","sun"],dayNames:{mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday",sun:"Sunday"},form:{address_line1:"",address_line2:"",city:"",state:"",zip_code:"",phone:"",email:"",website:"",description:"",lounge_type:""},hoursOpen:{},hoursClose:{},hoursClosed:{},amenitiesForm:{lounge_area:!1,wifi:!1,tv:!1,parking:!1,outdoor:!1,events:!1,private_lockers:!1},featuresForm:{walk_in_humidor:!1,smoke_inside:!1,handroll_service:!1,bar_type:"",food_type:"",gambling_gaming:!1,located_in:"",dress_code:"",atmosphere:[],live_entertainment:!1,entertainment_schedule_url:"",private_membership:!1,twenty_four_hour_access:!1,work_desk:!1,allows_outside_cigars:!1,cutting_fee:""},identityForm:{women_owned:!1,minority_owned:!1,veteran_owned:!1,languages:[]},socialForm:{facebook:"",instagram:"",tiktok:"",youtube:"",linkedin:"",twitter:""},newEvent:{title:"",description:"",event_date:""}}},computed:{token(){return localStorage.getItem("business_session_token")},isFeatured(){return this.lounge&&"featured"===this.lounge.tier},canEditIdentity(){return this.isFeatured}},methods:{toggleSection(e){this.sections[e]=!this.sections[e]},toggleLanguageDropdown(){this.canEditIdentity&&(this.languageDropdownOpen=!this.languageDropdownOpen)},removeLanguage(e){this.identityForm.languages=this.identityForm.languages.filter((s=>s!==e))},closeLanguageDropdown(e){this.$el.querySelector(".language-multiselect")&&this.$el.querySelector(".language-multiselect").contains(e.target)||(this.languageDropdownOpen=!1)},async loadLounge(){this.loading=!0;try{const e=await fetch(Gs.baseUrl+"api/v1/business/lounges/"+this.$route.params.id,{headers:{"Session-Token":this.token}});if(!e.ok)return this.lounge=null,void(this.loading=!1);const s=await e.json();this.lounge=s.lounge,this.populateForm()}catch(e){console.error(e)}this.loading=!1},populateForm(){const e=this.lounge;this.form={address_line1:e.address_line1||"",address_line2:e.address_line2||"",city:e.city||"",state:e.state||"",zip_code:e.zip_code||"",phone:e.phone||"",email:e.email||"",website:e.website||"",description:e.description||"",lounge_type:e.lounge_type||""},this.dayOrder.forEach((s=>{const i=(e.hours||{})[s];this.$set(this.hoursOpen,s,i&&i.open?i.open:"09:00"),this.$set(this.hoursClose,s,i&&i.close?i.close:"21:00"),this.$set(this.hoursClosed,s,!i||!i.open)}));const s=e.amenities||{};Object.keys(this.amenitiesForm).forEach((e=>{this.amenitiesForm[e]=!0===s[e]||"true"===s[e]}));const i=e.features||{};Object.keys(this.featuresForm).forEach((e=>{"atmosphere"===e?this.featuresForm[e]=i[e]||[]:"boolean"===typeof this.featuresForm[e]?this.featuresForm[e]=!0===i[e]||"true"===i[e]:this.featuresForm[e]=i[e]||""}));const t=e.identity||{};this.identityForm.women_owned=t.women_owned||!1,this.identityForm.minority_owned=t.minority_owned||!1,this.identityForm.veteran_owned=t.veteran_owned||!1,this.identityForm.languages=t.languages||[];const a=e.social_links||{};Object.keys(this.socialForm).forEach((e=>{this.socialForm[e]=a[e]||""})),this.$nextTick((()=>{this.initialLoaded=!0}))},async saveListing(){this.saving=!0,this.error=null,this.saveMsg=null;const e={};this.dayOrder.forEach((s=>{this.hoursClosed[s]||(e[s]={open:this.hoursOpen[s],close:this.hoursClose[s]})}));const s={...this.form,hours:e,amenities:this.amenitiesForm,features:this.featuresForm,identity:this.identityForm,social_links:this.socialForm};try{const e=await fetch(Gs.baseUrl+"api/v1/business/lounges/"+this.$route.params.id,{method:"PUT",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify(s)}),i=await e.json();if(!e.ok)return void(this.error=i.errors?i.errors.join(", "):"Save failed");this.lounge=i.lounge,this.saveMsg="Listing saved successfully!",this.hasChanges=!1,this.initialLoaded=!1,this.populateForm(),setTimeout((()=>{this.saveMsg=null}),3e3)}catch(i){this.error="Network error"}finally{this.saving=!1}},async uploadPhoto(e){const s=e.target.files[0];if(!s)return;const i=new FormData;i.append("image",s);try{const e=await fetch(Gs.baseUrl+"api/v1/business/lounges/"+this.$route.params.id+"/photos",{method:"POST",headers:{"Session-Token":this.token},body:i}),s=await e.json();e.ok?(this.lounge.photos.push(s.photo),this.$refs.photoInput.value=""):this.error=s.errors?s.errors.join(", "):"Upload failed"}catch(e){this.error="Upload failed"}},async deletePhoto(e){if(confirm("Delete this photo?"))try{await fetch(Gs.baseUrl+"api/v1/business/lounges/"+this.$route.params.id+"/photos/"+e,{method:"DELETE",headers:{"Session-Token":this.token}}),this.lounge.photos=this.lounge.photos.filter((s=>s.id!==e))}catch(s){this.error="Delete failed"}},async addEvent(){if(this.newEvent.title&&this.newEvent.event_date)try{const e=await fetch(Gs.baseUrl+"api/v1/business/lounges/"+this.$route.params.id+"/events",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify(this.newEvent)}),s=await e.json();e.ok?(this.lounge.events.push(s.event),this.newEvent={title:"",description:"",event_date:""}):this.error=s.errors?s.errors.join(", "):"Failed"}catch(e){this.error="Failed"}else this.error="Event title and date required"},async deleteEvent(e){if(confirm("Delete this event?"))try{await fetch(Gs.baseUrl+"api/v1/business/lounges/"+this.$route.params.id+"/events/"+e,{method:"DELETE",headers:{"Session-Token":this.token}}),this.lounge.events=this.lounge.events.filter((s=>s.id!==e))}catch(s){this.error="Delete failed"}},async loadOptions(){try{const e=await(0,Gs.fetchData)(Gs.baseUrl+"api/v1/lounges/feature_options");this.options=e,this.languageOptions=e.languages||[]}catch(e){console.error(e)}}},watch:{form:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},amenitiesForm:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},featuresForm:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},identityForm:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},socialForm:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},hoursOpen:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},hoursClose:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0},hoursClosed:{handler(){this.initialLoaded&&(this.hasChanges=!0)},deep:!0}},mounted(){document.title="Edit Listing - CigarFinder Business",this.token?(this.loadLounge(),this.loadOptions(),document.addEventListener("click",this.closeLanguageDropdown)):this.$router.push("/business/login")},beforeUnmount(){document.removeEventListener("click",this.closeLanguageDropdown)}},Zs=i(6262);const ei=(0,Zs.A)(Ks,[["render",Ys]]);var si=ei},9421:function(e,s,i){i.r(s),i.d(s,{default:function(){return Y}});var t=i(641),a=i(33),l=i(3751);const o={class:"biz-page"},n={class:"embed-container"},r={class:"embed-header"},d={key:0,class:"biz-card",style:{"text-align":"center"}},u={key:1,class:"loading"},c={key:2,class:"biz-card",style:{"text-align":"center"}},p={key:3},h={key:0,class:"lounge-select"},k=["value"],g={class:"embed-option"},b={class:"embed-preview"},m={class:"code-box"},v={class:"embed-option"},L={class:"size-tabs"},y=["onClick"],f={class:"size-use"},C={class:"badge-preview"},w={class:"badge-right"},_={key:0,class:"badge-stars"},F={class:"badge-biz-name"},E={class:"code-box"},S={class:"embed-option"},X={class:"widget-preview"},U={class:"widget-real"},W={class:"widget-header"},x={key:0,class:"widget-verified"},z={class:"widget-body"},P={class:"widget-name"},T={class:"widget-location"},V={key:0,class:"widget-rating-row"},I={class:"widget-stars"},M={class:"widget-score"},D={class:"widget-count"},B={class:"code-box"},Q={class:"embed-option"},O={class:"code-box"},j={class:"verify-section"},N={class:"verify-row"},q=["disabled"];function J(e,s,i,J,$,A){const R=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[(0,t.Lk)("div",n,[(0,t.Lk)("div",r,[(0,t.bF)(R,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[9]||(s[9]=[(0,t.eW)("← Back to Dashboard")]))),_:1}),s[10]||(s[10]=(0,t.Lk)("h1",null,"Get Your CigarFinder Badge",-1)),s[11]||(s[11]=(0,t.Lk)("p",{class:"embed-subtitle"},"Add a CigarFinder badge or link to your website and get premium listing features for free.",-1))]),s[34]||(s[34]=(0,t.Fv)('<div class="how-it-works"><h2>How It Works</h2><div class="steps-row"><div class="step-card"><div class="step-num">1</div><h3>Pick a Badge</h3><p>Choose from a text link, image badge, or live widget below.</p></div><div class="step-card"><div class="step-num">2</div><h3>Add to Your Site</h3><p>Copy the code and paste it into your website footer, sidebar, or partners page.</p></div><div class="step-card"><div class="step-num">3</div><h3>Verify &amp; Unlock</h3><p>Click &quot;Verify&quot; below and your listing gets premium features instantly — no charge.</p></div></div></div>',1)),A.isLoggedIn?$.loading?((0,t.uX)(),(0,t.CE)("div",u,s[15]||(s[15]=[(0,t.Lk)("p",null,"Loading your listings...",-1)]))):0===$.lounges.length?((0,t.uX)(),(0,t.CE)("div",c,[(0,t.Lk)("p",null,[s[17]||(s[17]=(0,t.eW)("You need to ")),(0,t.bF)(R,{to:"/lounges"},{default:(0,t.k6)((()=>s[16]||(s[16]=[(0,t.eW)("claim a listing")]))),_:1}),s[18]||(s[18]=(0,t.eW)(" first to get embed codes."))])])):((0,t.uX)(),(0,t.CE)("div",p,[$.lounges.length>1?((0,t.uX)(),(0,t.CE)("div",h,[s[19]||(s[19]=(0,t.Lk)("label",null,"Select listing:",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[0]||(s[0]=e=>$.selectedLoungeId=e)},[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)($.lounges,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.id,value:e.id},(0,a.v_)(e.name)+" - "+(0,a.v_)(e.city)+", "+(0,a.v_)(e.state),9,k)))),128))],512),[[l.u1,$.selectedLoungeId]])])):(0,t.Q3)("",!0),(0,t.Lk)("div",g,[s[20]||(s[20]=(0,t.Lk)("div",{class:"option-header"},[(0,t.Lk)("h2",null,"1. Simple Text Link"),(0,t.Lk)("span",{class:"option-tag"},"Easiest")],-1)),s[21]||(s[21]=(0,t.Lk)("p",{class:"embed-desc"},"One line of HTML — paste into your footer or sidebar.",-1)),(0,t.Lk)("div",b,[(0,t.Lk)("a",{href:"#",onClick:s[1]||(s[1]=(0,l.D$)((()=>{}),["prevent"])),style:{color:"#B26D28","text-decoration":"none","font-weight":"600","font-size":"14px"}},"Find us on CigarFinder")]),(0,t.Lk)("div",m,[(0,t.Lk)("code",null,(0,a.v_)(A.textLinkCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[2]||(s[2]=e=>A.copyCode(A.textLinkCode,"text"))},(0,a.v_)("text"===$.copied?"Copied!":"Copy"),1)])]),(0,t.Lk)("div",v,[s[25]||(s[25]=(0,t.Lk)("div",{class:"option-header"},[(0,t.Lk)("h2",null,"2. Badge Image"),(0,t.Lk)("span",{class:"option-tag popular"},"Most Popular")],-1)),s[26]||(s[26]=(0,t.Lk)("p",{class:"embed-desc"},"A visual badge linking back to your listing. Choose a size:",-1)),(0,t.Lk)("div",L,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)($.badgeSizes,(e=>((0,t.uX)(),(0,t.CE)("button",{key:e.key,onClick:s=>$.selectedSize=e.key,class:(0,a.C4)([{active:$.selectedSize===e.key},"size-tab"])},[(0,t.eW)((0,a.v_)(e.label),1),(0,t.Lk)("span",f,(0,a.v_)(e.use),1)],10,y)))),128))]),(0,t.Lk)("div",C,[(0,t.Lk)("div",{class:(0,a.C4)(["badge-real","badge-"+$.selectedSize])},[s[23]||(s[23]=(0,t.Lk)("div",{class:"badge-left"},[(0,t.Lk)("span",{class:"badge-logo"},[(0,t.eW)("Cigar"),(0,t.Lk)("span",{class:"badge-logo-sub"},"Finder")])],-1)),(0,t.Lk)("div",w,[A.selectedLounge.rating?((0,t.uX)(),(0,t.CE)("span",_,(0,a.v_)(e.starStr(A.selectedLounge.rating)),1)):(0,t.Q3)("",!0),(0,t.Lk)("span",F,(0,a.v_)(A.loungeName),1),s[22]||(s[22]=(0,t.Lk)("span",{class:"badge-cta"},"Find us on CigarFinder →",-1))])],2),s[24]||(s[24]=(0,t.Lk)("p",{class:"preview-note"},"Preview — your badge will look like this on your website",-1))]),(0,t.Lk)("div",E,[(0,t.Lk)("code",null,(0,a.v_)(A.badgeCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[3]||(s[3]=e=>A.copyCode(A.badgeCode,"badge"))},(0,a.v_)("badge"===$.copied?"Copied!":"Copy"),1)])]),(0,t.Lk)("div",S,[s[28]||(s[28]=(0,t.Lk)("div",{class:"option-header"},[(0,t.Lk)("h2",null,"3. Live Widget")],-1)),s[29]||(s[29]=(0,t.Lk)("p",{class:"embed-desc"},"Shows your live rating and review count — updates automatically.",-1)),(0,t.Lk)("div",X,[(0,t.Lk)("div",U,[(0,t.Lk)("div",W,[s[27]||(s[27]=(0,t.Lk)("span",{class:"widget-logo"},[(0,t.eW)("Cigar"),(0,t.Lk)("span",{class:"widget-logo-sub"},"Finder")],-1)),A.selectedLounge.claimed?((0,t.uX)(),(0,t.CE)("span",x,"✓ Verified")):(0,t.Q3)("",!0)]),(0,t.Lk)("div",z,[(0,t.Lk)("span",P,(0,a.v_)(A.loungeName),1),(0,t.Lk)("span",T,(0,a.v_)(A.selectedLounge.city)+", "+(0,a.v_)(A.selectedLounge.state),1),A.selectedLounge.google_rating||A.selectedLounge.rating?((0,t.uX)(),(0,t.CE)("div",V,[(0,t.Lk)("span",I,(0,a.v_)(e.starStr(A.selectedLounge.google_rating||A.selectedLounge.rating)),1),(0,t.Lk)("span",M,(0,a.v_)(A.selectedLounge.google_rating||A.selectedLounge.rating),1),(0,t.Lk)("span",D,"("+(0,a.v_)(A.selectedLounge.google_review_count||A.selectedLounge.review_count||0)+" reviews)",1)])):(0,t.Q3)("",!0)]),(0,t.Lk)("a",{href:"#",onClick:s[4]||(s[4]=(0,l.D$)((()=>{}),["prevent"])),class:"widget-cta-btn"},"View on CigarFinder →")])]),(0,t.Lk)("div",B,[(0,t.Lk)("code",null,(0,a.v_)(A.widgetCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[5]||(s[5]=e=>A.copyCode(A.widgetCode,"widget"))},(0,a.v_)("widget"===$.copied?"Copied!":"Copy"),1)])]),(0,t.Lk)("div",Q,[s[30]||(s[30]=(0,t.Lk)("div",{class:"option-header"},[(0,t.Lk)("h2",null,"4. iframe Embed")],-1)),s[31]||(s[31]=(0,t.Lk)("p",{class:"embed-desc"},"For sites that block external JavaScript (WordPress.com, Squarespace, etc.).",-1)),(0,t.Lk)("div",O,[(0,t.Lk)("code",null,(0,a.v_)(A.iframeCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[6]||(s[6]=e=>A.copyCode(A.iframeCode,"iframe"))},(0,a.v_)("iframe"===$.copied?"Copied!":"Copy"),1)])]),(0,t.Lk)("div",j,[s[32]||(s[32]=(0,t.Lk)("h2",null,"Verify Your Backlink",-1)),s[33]||(s[33]=(0,t.Lk)("p",null,"Paste the URL of the page where you added the code:",-1)),(0,t.Lk)("div",N,[(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[7]||(s[7]=e=>$.verifyUrl=e),placeholder:"https://yoursite.com/partners",class:"verify-input"},null,512),[[l.Jo,$.verifyUrl]]),(0,t.Lk)("button",{class:"verify-btn",onClick:s[8]||(s[8]=(...e)=>A.verifyBacklink&&A.verifyBacklink(...e)),disabled:$.verifying},(0,a.v_)($.verifying?"Checking...":"Verify"),9,q)]),$.verifyResult?((0,t.uX)(),(0,t.CE)("p",{key:0,class:(0,a.C4)($.verifyResult.success?"verify-success":"verify-fail")},(0,a.v_)($.verifyResult.message),3)):(0,t.Q3)("",!0)])])):((0,t.uX)(),(0,t.CE)("div",d,[(0,t.Lk)("p",null,[s[13]||(s[13]=(0,t.eW)("Please ")),(0,t.bF)(R,{to:"/business/login"},{default:(0,t.k6)((()=>s[12]||(s[12]=[(0,t.eW)("log in")]))),_:1}),s[14]||(s[14]=(0,t.eW)(" to view your embed codes."))])]))])])}i(8992),i(2577);var $=i(7465),A={name:"BusinessEmbedCodes",data(){return{lounges:[],selectedLoungeId:null,loading:!0,selectedSize:"medium",copied:null,verifyUrl:"",verifying:!1,verifyResult:null,badgeSizes:[{key:"small",label:"150x50",use:"Footer"},{key:"medium",label:"300x100",use:"Sidebar"},{key:"leaderboard",label:"728x90",use:"Banner"},{key:"rectangle",label:"300x250",use:"Widget"}]}},computed:{isLoggedIn(){return!!localStorage.getItem("business_session_token")},token(){return localStorage.getItem("business_session_token")},selectedLounge(){return this.lounges.find((e=>e.id===this.selectedLoungeId))||{}},loungeSlug(){return this.selectedLounge.slug||""},loungeName(){return this.selectedLounge.name||"Your Business"},loungeUrl(){return"https://cigarfinder.com/lounges/"+this.loungeSlug},cdnUrl(){return"https://cigarfinder.com"},textLinkCode(){return'<a href="'+this.loungeUrl+'" target="_blank" rel="noopener">Find us on CigarFinder</a>'},badgeCode(){var e={small:"150x50",medium:"300x100",leaderboard:"728x90",rectangle:"300x250"},s=e[this.selectedSize]||"300x100",i=s.split("x");return'<a href="'+this.loungeUrl+'" target="_blank" rel="noopener"><img src="'+this.cdnUrl+"/badges/find-us-"+s+'.png" alt="Find '+this.loungeName+' on CigarFinder" width="'+i[0]+'" height="'+i[1]+'" style="border:0;" /></a>'},widgetCode(){var e="script";return'<div id="cigarfinder-badge" data-slug="'+this.loungeSlug+'" data-theme="dark"></div>\n<'+e+' src="'+this.cdnUrl+'/widget/badge.js" async></'+e+">"},iframeCode(){return'<iframe src="'+this.cdnUrl+"/embed/badge/"+this.loungeSlug+'" width="300" height="120" frameborder="0" style="border:none;overflow:hidden;" title="'+this.loungeName+' on CigarFinder"></iframe>'},badgePreviewStyle(){var e={small:{w:150,h:50},medium:{w:300,h:100},leaderboard:{w:364,h:45},rectangle:{w:200,h:166}},s=e[this.selectedSize]||e.medium;return{width:s.w+"px",height:s.h+"px"}}},methods:{async loadDashboard(){this.loading=!0;try{var e=await fetch($.baseUrl+"api/v1/business/dashboard",{headers:{"Session-Token":this.token}});if(!e.ok)return void(this.loading=!1);var s=await e.json();this.lounges=s.lounges||[],this.lounges.length&&(this.selectedLoungeId=this.lounges[0].id)}catch(i){console.error(i)}this.loading=!1},copyCode(e,s){navigator.clipboard.writeText(e).then((()=>{this.copied=s||"text",setTimeout((()=>{this.copied=null}),2e3)})).catch((()=>{}))},async verifyBacklink(){if(this.verifyUrl){this.verifying=!0,this.verifyResult=null;try{var e=await fetch($.baseUrl+"api/v1/business/backlink_verify",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify({url:this.verifyUrl})}),s=await e.json();this.verifyResult=e.ok?{success:!0,message:"Backlink detected! Your listing benefits are now active."}:{success:!1,message:s.errors?s.errors.join(", "):"Backlink not found. Make sure the code is on a publicly accessible page."}}catch(i){this.verifyResult={success:!1,message:"Verification failed. Please try again."}}this.verifying=!1}}},created(){document.title="Embed Codes - CigarFinder Business",this.isLoggedIn?this.loadDashboard():this.loading=!1}},R=i(6262);const H=(0,R.A)(A,[["render",J]]);var Y=H},5769:function(e,s,i){i.r(s),i.d(s,{default:function(){return y}});i(4114);var t=i(641),a=i(3751),l=i(33);const o={class:"biz-page"},n={class:"biz-container"},r={class:"biz-card"},d={class:"biz-sub"},u={class:"biz-field"},c={class:"biz-field"},p={key:0,class:"biz-error"},h=["disabled"],k={class:"biz-forgot"};function g(e,s,i,g,b,m){return(0,t.uX)(),(0,t.CE)("div",o,[(0,t.Lk)("div",n,[s[9]||(s[9]=(0,t.Lk)("div",{class:"biz-header"},[(0,t.Lk)("h1",null,"Business Portal Login"),(0,t.Lk)("p",null,"Manage your cigar lounge or shop listing on CigarFinder")],-1)),(0,t.Lk)("div",r,[s[8]||(s[8]=(0,t.Lk)("h2",null,"Log In",-1)),(0,t.Lk)("p",d,[s[5]||(s[5]=(0,t.eW)("Don't have an account? ")),(0,t.Lk)("a",{onClick:s[0]||(s[0]=(0,a.D$)((s=>e.$router.push("/business/register")),["prevent"])),class:"biz-link"},"Create one")]),(0,t.Lk)("form",{onSubmit:s[3]||(s[3]=(0,a.D$)(((...e)=>m.handleLogin&&m.handleLogin(...e)),["prevent"]))},[(0,t.Lk)("div",u,[s[6]||(s[6]=(0,t.Lk)("label",null,"Email",-1)),(0,t.bo)((0,t.Lk)("input",{type:"email","onUpdate:modelValue":s[1]||(s[1]=e=>b.email=e),placeholder:"you@yourbusiness.com",required:""},null,512),[[a.Jo,b.email]])]),(0,t.Lk)("div",c,[s[7]||(s[7]=(0,t.Lk)("label",null,"Password",-1)),(0,t.bo)((0,t.Lk)("input",{type:"password","onUpdate:modelValue":s[2]||(s[2]=e=>b.password=e),placeholder:"Your password",required:""},null,512),[[a.Jo,b.password]])]),b.error?((0,t.uX)(),(0,t.CE)("p",p,(0,l.v_)(b.error),1)):(0,t.Q3)("",!0),(0,t.Lk)("button",{type:"submit",class:"biz-btn",disabled:b.loading},(0,l.v_)(b.loading?"Logging in...":"Log In"),9,h)],32),(0,t.Lk)("p",k,[(0,t.Lk)("a",{onClick:s[4]||(s[4]=(0,a.D$)(((...e)=>m.forgotPw&&m.forgotPw(...e)),["prevent"])),class:"biz-link"},"Forgot your password?")])])])])}var b=i(7465),m={name:"BusinessLogin",data(){return{email:"",password:"",error:null,loading:!1}},methods:{async handleLogin(){this.error=null,this.loading=!0;try{const e=await fetch(b.baseUrl+"api/v1/business/login",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:this.email,password:this.password})}),s=await e.json();if(!e.ok)return void(this.error=s.errors?s.errors.join(", "):"Login failed");localStorage.setItem("business_session_token",s.session_token),localStorage.setItem("business_user",JSON.stringify(s.current_user)),this.$router.push("/business/dashboard")}catch(e){this.error="Network error. Please try again."}finally{this.loading=!1}},forgotPw(){alert("Password reset coming soon. Contact support@cigarfinder.com for now.")}},created(){document.title="Business Login - CigarFinder",localStorage.getItem("business_session_token")&&this.$router.push("/business/dashboard")}},v=i(6262);const L=(0,v.A)(m,[["render",g]]);var y=L},5809:function(e,s,i){i.r(s),i.d(s,{default:function(){return x}});var t=i(641),a=i(3751),l=i(33);const o={class:"biz-page"},n={class:"profile-container"},r={class:"edit-header"},d={key:0,class:"biz-card"},u={class:"biz-field"},c={class:"biz-field"},p=["value"],h={class:"biz-field"},k={key:0,class:"edit-success"},g=["disabled"],b={class:"biz-card",style:{"margin-top":"16px"}},m={class:"biz-field"},v={class:"biz-field"},L={key:0,class:"biz-error"},y={key:1,class:"edit-success"},f=["disabled"],C={class:"biz-card",style:{"margin-top":"16px"}},w={class:"status-row"},_={class:"status-row"},F={class:"status-row"};function E(e,s,i,E,S,X){const U=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[(0,t.Lk)("div",n,[(0,t.Lk)("div",r,[s[7]||(s[7]=(0,t.Lk)("h1",null,"My Profile",-1)),(0,t.bF)(U,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[6]||(s[6]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),S.user?((0,t.uX)(),(0,t.CE)("div",d,[s[12]||(s[12]=(0,t.Lk)("h2",null,"Account Information",-1)),(0,t.Lk)("form",{onSubmit:s[2]||(s[2]=(0,a.D$)(((...e)=>X.saveProfile&&X.saveProfile(...e)),["prevent"]))},[(0,t.Lk)("div",u,[s[8]||(s[8]=(0,t.Lk)("label",null,"Full Name",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[0]||(s[0]=e=>S.name=e)},null,512),[[a.Jo,S.name]])]),(0,t.Lk)("div",c,[s[9]||(s[9]=(0,t.Lk)("label",null,"Email",-1)),(0,t.Lk)("input",{type:"email",value:S.user.email,disabled:"",class:"disabled-input"},null,8,p),s[10]||(s[10]=(0,t.Lk)("span",{class:"field-hint"},"Contact support to change your email",-1))]),(0,t.Lk)("div",h,[s[11]||(s[11]=(0,t.Lk)("label",null,"Phone",-1)),(0,t.bo)((0,t.Lk)("input",{type:"tel","onUpdate:modelValue":s[1]||(s[1]=e=>S.phone=e),placeholder:"+1 (555) 123-4567"},null,512),[[a.Jo,S.phone]])]),S.saved?((0,t.uX)(),(0,t.CE)("p",k,"Profile updated!")):(0,t.Q3)("",!0),(0,t.Lk)("button",{type:"submit",class:"biz-btn",disabled:S.saving},(0,l.v_)(S.saving?"Saving...":"Save Profile"),9,g)],32)])):(0,t.Q3)("",!0),(0,t.Lk)("div",b,[s[15]||(s[15]=(0,t.Lk)("h2",null,"Change Password",-1)),(0,t.Lk)("form",{onSubmit:s[5]||(s[5]=(0,a.D$)(((...e)=>X.changePassword&&X.changePassword(...e)),["prevent"]))},[(0,t.Lk)("div",m,[s[13]||(s[13]=(0,t.Lk)("label",null,"New Password",-1)),(0,t.bo)((0,t.Lk)("input",{type:"password","onUpdate:modelValue":s[3]||(s[3]=e=>S.newPassword=e),placeholder:"Minimum 6 characters",minlength:"6"},null,512),[[a.Jo,S.newPassword]])]),(0,t.Lk)("div",v,[s[14]||(s[14]=(0,t.Lk)("label",null,"Confirm New Password",-1)),(0,t.bo)((0,t.Lk)("input",{type:"password","onUpdate:modelValue":s[4]||(s[4]=e=>S.confirmPassword=e),placeholder:"Confirm new password"},null,512),[[a.Jo,S.confirmPassword]])]),S.pwError?((0,t.uX)(),(0,t.CE)("p",L,(0,l.v_)(S.pwError),1)):(0,t.Q3)("",!0),S.pwSaved?((0,t.uX)(),(0,t.CE)("p",y,"Password changed!")):(0,t.Q3)("",!0),(0,t.Lk)("button",{type:"submit",class:"biz-btn",disabled:S.pwSaving},(0,l.v_)(S.pwSaving?"Changing...":"Change Password"),9,f)],32)]),(0,t.Lk)("div",C,[s[22]||(s[22]=(0,t.Lk)("h2",null,"Account Status",-1)),(0,t.Lk)("div",w,[s[16]||(s[16]=(0,t.Lk)("span",null,"Email verified:",-1)),s[17]||(s[17]=(0,t.eW)()),(0,t.Lk)("strong",{style:(0,l.Tr)({color:S.user.confirmed?"#27ae60":"#e67e22"})},(0,l.v_)(S.user.confirmed?"Yes":"Not yet"),5)]),(0,t.Lk)("div",_,[s[18]||(s[18]=(0,t.Lk)("span",null,"Member since:",-1)),s[19]||(s[19]=(0,t.eW)()),(0,t.Lk)("strong",null,(0,l.v_)(new Date(S.user.created_at).toLocaleDateString("en-US",{month:"long",day:"numeric",year:"numeric"})),1)]),(0,t.Lk)("div",F,[s[20]||(s[20]=(0,t.Lk)("span",null,"Listings:",-1)),s[21]||(s[21]=(0,t.eW)()),(0,t.Lk)("strong",null,(0,l.v_)(S.user.lounges_count),1)])])])])}i(4114);var S=i(7465),X={name:"BusinessProfile",data(){return{user:null,name:"",phone:"",saving:!1,saved:!1,newPassword:"",confirmPassword:"",pwSaving:!1,pwSaved:!1,pwError:null}},computed:{token(){return localStorage.getItem("business_session_token")}},methods:{async loadProfile(){try{const e=await fetch(S.baseUrl+"api/v1/business/profile",{headers:{"Session-Token":this.token}}),s=await e.json();this.user=s.current_user,this.name=this.user.full_name,this.phone=this.user.phone||""}catch(e){console.error(e)}},async saveProfile(){this.saving=!0,this.saved=!1,setTimeout((()=>{this.saved=!0,this.saving=!1}),500)},async changePassword(){this.pwError=null,this.pwSaved=!1,this.newPassword===this.confirmPassword?this.newPassword.length<6?this.pwError="Password must be at least 6 characters":(this.pwSaving=!0,setTimeout((()=>{this.pwSaved=!0,this.pwSaving=!1,this.newPassword="",this.confirmPassword=""}),500)):this.pwError="Passwords do not match"}},mounted(){document.title="My Profile - CigarFinder Business",this.token?this.loadProfile():this.$router.push("/business/login")}},U=i(6262);const W=(0,U.A)(X,[["render",E]]);var x=W},677:function(e,s,i){i.r(s),i.d(s,{default:function(){return F}});i(4114);var t=i(641),a=i(3751),l=i(33);const o={class:"biz-page"},n={key:0,class:"biz-container"},r={class:"biz-card"},d={class:"biz-sub"},u={class:"biz-field"},c={class:"biz-field"},p={class:"biz-field"},h={class:"biz-field"},k={class:"biz-field"},g={key:0,class:"biz-error"},b=["disabled"],m={key:1,class:"biz-container"},v={class:"biz-card",style:{"text-align":"center"}},L={style:{color:"#bbb","margin-bottom":"16px"}};function y(e,s,i,y,f,C){return(0,t.uX)(),(0,t.CE)("div",o,[f.registered?((0,t.uX)(),(0,t.CE)("div",m,[(0,t.Lk)("div",v,[s[17]||(s[17]=(0,t.Lk)("h2",null,"Account Created!",-1)),(0,t.Lk)("p",L,"Welcome, "+(0,l.v_)(f.registeredName)+". Your business account is ready.",1),(0,t.Lk)("button",{onClick:s[7]||(s[7]=s=>e.$router.push("/business/dashboard")),class:"biz-btn"},"Go to Dashboard")])])):((0,t.uX)(),(0,t.CE)("div",n,[s[16]||(s[16]=(0,t.Lk)("div",{class:"biz-header"},[(0,t.Lk)("h1",null,"List Your Business on CigarFinder"),(0,t.Lk)("p",null,"Reach thousands of cigar enthusiasts searching for lounges and shops near them.")],-1)),(0,t.Lk)("div",r,[s[14]||(s[14]=(0,t.Lk)("h2",null,"Create Your Business Account",-1)),(0,t.Lk)("p",d,[s[8]||(s[8]=(0,t.eW)("Already have an account? ")),(0,t.Lk)("a",{onClick:s[0]||(s[0]=(0,a.D$)((s=>e.$router.push("/business/login")),["prevent"])),class:"biz-link"},"Log in")]),(0,t.Lk)("form",{onSubmit:s[6]||(s[6]=(0,a.D$)(((...e)=>C.handleRegister&&C.handleRegister(...e)),["prevent"]))},[(0,t.Lk)("div",u,[s[9]||(s[9]=(0,t.Lk)("label",null,"Full Name *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[1]||(s[1]=e=>f.form.full_name=e),placeholder:"Your full name",required:""},null,512),[[a.Jo,f.form.full_name]])]),(0,t.Lk)("div",c,[s[10]||(s[10]=(0,t.Lk)("label",null,"Business Email *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"email","onUpdate:modelValue":s[2]||(s[2]=e=>f.form.email=e),placeholder:"you@yourbusiness.com",required:""},null,512),[[a.Jo,f.form.email]])]),(0,t.Lk)("div",p,[s[11]||(s[11]=(0,t.Lk)("label",null,"Phone Number",-1)),(0,t.bo)((0,t.Lk)("input",{type:"tel","onUpdate:modelValue":s[3]||(s[3]=e=>f.form.phone=e),placeholder:"+1 (555) 123-4567"},null,512),[[a.Jo,f.form.phone]])]),(0,t.Lk)("div",h,[s[12]||(s[12]=(0,t.Lk)("label",null,"Password *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"password","onUpdate:modelValue":s[4]||(s[4]=e=>f.form.password=e),placeholder:"Minimum 6 characters",required:"",minlength:"6"},null,512),[[a.Jo,f.form.password]])]),(0,t.Lk)("div",k,[s[13]||(s[13]=(0,t.Lk)("label",null,"Confirm Password *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"password","onUpdate:modelValue":s[5]||(s[5]=e=>f.form.password_confirmation=e),placeholder:"Confirm your password",required:""},null,512),[[a.Jo,f.form.password_confirmation]])]),f.error?((0,t.uX)(),(0,t.CE)("p",g,(0,l.v_)(f.error),1)):(0,t.Q3)("",!0),(0,t.Lk)("button",{type:"submit",class:"biz-btn",disabled:f.loading},(0,l.v_)(f.loading?"Creating Account...":"Create Business Account"),9,b)],32),s[15]||(s[15]=(0,t.Lk)("div",{class:"biz-benefits"},[(0,t.Lk)("h3",null,"Why list your business?"),(0,t.Lk)("ul",null,[(0,t.Lk)("li",null,'Get found by cigar enthusiasts searching "cigar lounge near me"'),(0,t.Lk)("li",null,"Free listing when you add a CigarFinder badge to your website"),(0,t.Lk)("li",null,"Manage your hours, photos, events, and social links"),(0,t.Lk)("li",null,"Basic listings start at just $29/year")])],-1))])]))])}var f=i(7465),C={name:"BusinessRegister",data(){return{form:{full_name:"",email:"",phone:"",password:"",password_confirmation:""},error:null,loading:!1,registered:!1,registeredName:""}},methods:{async handleRegister(){if(this.error=null,this.form.password===this.form.password_confirmation){this.loading=!0;try{const e=await fetch(f.baseUrl+"api/v1/business/register",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(this.form)}),s=await e.json();if(!e.ok)return void(this.error=s.errors?s.errors.join(", "):"Registration failed");localStorage.setItem("business_session_token",s.session_token),localStorage.setItem("business_user",JSON.stringify(s.current_user)),this.registeredName=s.current_user.full_name,this.registered=!0}catch(e){this.error="Network error. Please try again."}finally{this.loading=!1}}else this.error="Passwords do not match"}},created(){document.title="List Your Business - CigarFinder Store Locator",localStorage.getItem("business_session_token")&&this.$router.push("/business/dashboard")}},w=i(6262);const _=(0,w.A)(C,[["render",y]]);var F=_},1614:function(e,s,i){i.r(s),i.d(s,{default:function(){return I}});var t=i(641),a=i(33);const l={class:"biz-page"},o={class:"sub-container"},n={class:"edit-header"},r={key:0,class:"current-plan"},d={key:0,class:"plan-note"},u={key:1,class:"plan-note"},c={class:"plans-table"},p={class:"plans-grid"},h={class:"plan-action"},k={key:0,class:"current-label"},g={class:"plan-action"},b={key:0,class:"current-label"},m=["disabled"],v={class:"plan-action"},L={key:0,class:"current-label"},y=["disabled"],f={key:1,class:"billing-section"},C={class:"billing-card"},w={class:"billing-row"},_={class:"billing-row"},F={key:0,class:"billing-row"},E={key:1,class:"billing-row"},S={class:"billing-actions"},X=["disabled"],U={key:2,class:"biz-error"},W={key:3,class:"no-lounge-state"};function x(e,s,i,x,z,P){const T=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",l,[(0,t.Lk)("div",o,[(0,t.Lk)("div",n,[s[5]||(s[5]=(0,t.Lk)("h1",null,"Manage Subscription",-1)),(0,t.bF)(T,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[4]||(s[4]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),z.lounge?((0,t.uX)(),(0,t.CE)("div",r,[(0,t.Lk)("h2",null,(0,a.v_)(z.lounge.name),1),(0,t.Lk)("div",{class:(0,a.C4)(["plan-badge",z.lounge.tier])},(0,a.v_)("featured"===z.lounge.tier?"★ Featured":"basic"===z.lounge.tier?"Basic":"Free"),3),"free"!==z.lounge.tier||z.lounge.backlink_url?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("p",d,"Your listing is on the free tier with limited features.")),"free"===z.lounge.tier&&z.lounge.backlink_url?((0,t.uX)(),(0,t.CE)("p",u,"Free with backlink — your CigarFinder link is active.")):(0,t.Q3)("",!0)])):(0,t.Q3)("",!0),(0,t.Lk)("div",c,[s[10]||(s[10]=(0,t.Lk)("h2",null,"Choose Your Plan",-1)),(0,t.Lk)("div",p,[(0,t.Lk)("div",{class:(0,a.C4)(["plan-card",{active:"free"===P.currentTier}])},[s[7]||(s[7]=(0,t.Fv)('<div class="plan-head"><h3>Free</h3><div class="plan-price">$0<span>/year</span></div><p class="plan-req">Requires CigarFinder link on your website</p></div><ul class="plan-features"><li class="yes">Basic listing (name, address, phone)</li><li class="yes">Business hours</li><li class="yes">Map pin</li><li class="yes">1 photo</li><li class="yes">Verified badge</li><li class="no">Website link shown</li><li class="no">Social profiles</li><li class="no">Events</li><li class="no">Featured placement</li><li class="no">Full features &amp; identity</li></ul>',2)),(0,t.Lk)("div",h,["free"===P.currentTier?((0,t.uX)(),(0,t.CE)("span",k,"Current Plan")):((0,t.uX)(),(0,t.Wv)(T,{key:1,to:"/business/embed-codes",class:"plan-btn-outline"},{default:(0,t.k6)((()=>s[6]||(s[6]=[(0,t.eW)("Get Free with Backlink")]))),_:1}))])],2),(0,t.Lk)("div",{class:(0,a.C4)(["plan-card",{active:"basic"===P.currentTier}])},[s[8]||(s[8]=(0,t.Fv)('<div class="plan-head"><h3>Basic</h3><div class="plan-price">$29<span>/year</span></div><p class="plan-req">No backlink required</p></div><ul class="plan-features"><li class="yes">Everything in Free</li><li class="yes">Website link shown</li><li class="yes">3 photos</li><li class="yes">Description editable</li><li class="yes">Basic features shown</li><li class="no">Social profiles</li><li class="no">Events</li><li class="no">Featured placement</li><li class="no">Full features &amp; identity</li></ul>',2)),(0,t.Lk)("div",g,["basic"===P.currentTier?((0,t.uX)(),(0,t.CE)("span",b,"Current Plan")):((0,t.uX)(),(0,t.CE)("button",{key:1,class:"plan-btn",onClick:s[0]||(s[0]=e=>P.subscribe("basic")),disabled:z.subscribing},(0,a.v_)(z.subscribing?"Loading...":"Upgrade — $29/yr"),9,m))])],2),(0,t.Lk)("div",{class:(0,a.C4)(["plan-card featured-plan",{active:"featured"===P.currentTier}])},[s[9]||(s[9]=(0,t.Fv)('<div class="plan-popular">Most Popular</div><div class="plan-head"><h3>★ Featured</h3><div class="plan-price">$149<span>/year</span></div><p class="plan-req">Or FREE with dofollow backlink</p></div><ul class="plan-features"><li class="yes">Everything in Basic</li><li class="yes">Unlimited photos</li><li class="yes">Social profiles (IG, FB, TikTok, etc.)</li><li class="yes">Events promotion</li><li class="yes">★ Featured placement at top of city</li><li class="yes">All features &amp; identity badges</li><li class="yes">Live entertainment schedule</li><li class="yes">Private membership display</li><li class="yes">Priority in &quot;near me&quot; results</li></ul>',3)),(0,t.Lk)("div",v,["featured"===P.currentTier?((0,t.uX)(),(0,t.CE)("span",L,"Current Plan")):((0,t.uX)(),(0,t.CE)("button",{key:1,class:"plan-btn featured-btn",onClick:s[1]||(s[1]=e=>P.subscribe("featured")),disabled:z.subscribing},(0,a.v_)(z.subscribing?"Loading...":"Go Featured — $149/yr"),9,y))])],2)])]),z.subscription?((0,t.uX)(),(0,t.CE)("div",f,[s[15]||(s[15]=(0,t.Lk)("h2",null,"Billing",-1)),(0,t.Lk)("div",C,[(0,t.Lk)("div",w,[s[11]||(s[11]=(0,t.Lk)("span",null,"Plan:",-1)),(0,t.Lk)("strong",null,(0,a.v_)(z.subscription.tier),1)]),(0,t.Lk)("div",_,[s[12]||(s[12]=(0,t.Lk)("span",null,"Status:",-1)),(0,t.Lk)("strong",{class:(0,a.C4)(z.subscription.status)},(0,a.v_)(z.subscription.status),3)]),z.subscription.current_period_end?((0,t.uX)(),(0,t.CE)("div",F,[s[13]||(s[13]=(0,t.Lk)("span",null,"Next renewal:",-1)),(0,t.Lk)("strong",null,(0,a.v_)(new Date(z.subscription.current_period_end).toLocaleDateString("en-US",{month:"long",day:"numeric",year:"numeric"})),1)])):(0,t.Q3)("",!0),z.subscription.cancel_at_period_end?((0,t.uX)(),(0,t.CE)("div",E,s[14]||(s[14]=[(0,t.Lk)("span",{class:"cancel-warning"},"Your subscription will cancel at the end of the current billing period.",-1)]))):(0,t.Q3)("",!0),(0,t.Lk)("div",S,[(0,t.Lk)("button",{class:"biz-btn-sm",onClick:s[2]||(s[2]=(...e)=>P.openPortal&&P.openPortal(...e)),disabled:z.portalLoading},(0,a.v_)(z.portalLoading?"Loading...":"Update Payment Method"),9,X),z.subscription.cancel_at_period_end?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("button",{key:0,class:"cancel-btn",onClick:s[3]||(s[3]=(...e)=>P.cancelSub&&P.cancelSub(...e))},"Cancel Subscription"))])])])):(0,t.Q3)("",!0),z.error?((0,t.uX)(),(0,t.CE)("p",U,(0,a.v_)(z.error),1)):(0,t.Q3)("",!0),z.lounge||z.loading||z.error?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",W,[s[17]||(s[17]=(0,t.Lk)("h2",null,"No Listing Found",-1)),s[18]||(s[18]=(0,t.Lk)("p",null,"Please claim or create a listing first before managing your subscription.",-1)),(0,t.bF)(T,{to:"/business/dashboard",class:"plan-btn"},{default:(0,t.k6)((()=>s[16]||(s[16]=[(0,t.eW)("Go to Dashboard")]))),_:1})]))])])}i(4114);var z=i(7465),P={name:"BusinessSubscription",data(){return{lounge:null,subscription:null,loading:!0,subscribing:!1,portalLoading:!1,error:null}},computed:{token(){return localStorage.getItem("business_session_token")},currentTier(){return this.lounge?this.lounge.tier:"free"}},methods:{async loadData(){this.loading=!0;try{const e=this.$route.params.id||this.$route.query.lounge_id||localStorage.getItem("business_active_lounge_id");if(e){const s=await fetch(z.baseUrl+"api/v1/business/subscription?lounge_id="+e,{headers:{"Session-Token":this.token}}),i=await s.json();this.lounge=i.lounge,this.subscription=i.subscription}else{const e=await fetch(z.baseUrl+"api/v1/business/dashboard",{headers:{"Session-Token":this.token}}),s=await e.json();s.lounges&&s.lounges.length&&(this.lounge=s.lounges[0],this.subscription=s.lounges[0].subscription)}}catch(e){console.error(e)}this.loading=!1},async subscribe(e){if(this.subscribing=!0,this.error=null,!this.lounge||!this.lounge.id)return this.error="Please claim a listing first before choosing a plan.",void(this.subscribing=!1);try{const s=await fetch(z.baseUrl+"api/v1/business/subscription",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify({tier:e,lounge_id:this.lounge.id})}),i=await s.json();i.checkout_url?window.location.href=i.checkout_url:this.error=i.errors?i.errors.join(", "):"Failed to start checkout"}catch(s){this.error="Network error"}finally{this.subscribing=!1}},async openPortal(){this.portalLoading=!0;try{const e=await fetch(z.baseUrl+"api/v1/business/subscription/portal",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify({lounge_id:this.lounge.id})}),s=await e.json();s.portal_url?window.location.href=s.portal_url:this.error=s.errors?s.errors.join(", "):"Failed"}catch(e){this.error="Network error"}finally{this.portalLoading=!1}},async cancelSub(){if(confirm("Are you sure you want to cancel? Your listing will downgrade to free at the end of your billing period."))try{const e=await fetch(z.baseUrl+"api/v1/business/subscription/"+this.subscription.id,{method:"DELETE",headers:{"Session-Token":this.token}}),s=await e.json();e.ok?this.subscription.cancel_at_period_end=!0:this.error=s.errors?s.errors.join(", "):"Cancel failed"}catch(e){this.error="Network error"}}},mounted(){document.title="Manage Subscription - CigarFinder Business",this.token?this.loadData():this.$router.push("/business/login")}},T=i(6262);const V=(0,T.A)(P,[["render",x]]);var I=V},5777:function(e,s,i){i.r(s),i.d(s,{default:function(){return S}});var t=i(641),a=i(3751),l=i(33);const o={class:"biz-page"},n={class:"support-container"},r={class:"edit-header"},d={key:0,class:"biz-card"},u={class:"biz-field"},c={class:"biz-field"},p=["value"],h={class:"biz-field"},k={key:0,class:"biz-error"},g=["disabled"],b={key:1,class:"biz-card",style:{"text-align":"center"}},m={key:2,class:"tickets-section"},v={class:"ticket-head"},L={class:"ticket-date"},y={class:"ticket-msg"},f={key:0,class:"ticket-response"};function C(e,s,i,C,w,_){const F=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",o,[(0,t.Lk)("div",n,[(0,t.Lk)("div",r,[s[6]||(s[6]=(0,t.Lk)("h1",null,"Help & Support",-1)),(0,t.bF)(F,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[5]||(s[5]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),w.submitted?((0,t.uX)(),(0,t.CE)("div",b,[s[12]||(s[12]=(0,t.Lk)("h2",{style:{color:"#27ae60"}},"Ticket Submitted!",-1)),s[13]||(s[13]=(0,t.Lk)("p",{style:{color:"#bbb"}},"We'll respond within 24-48 hours via email.",-1)),(0,t.Lk)("button",{onClick:s[4]||(s[4]=e=>w.submitted=!1),class:"biz-btn-sm",style:{"margin-top":"12px"}},"Submit Another")])):((0,t.uX)(),(0,t.CE)("div",d,[s[11]||(s[11]=(0,t.Lk)("h2",null,"Submit a Support Request",-1)),(0,t.Lk)("form",{onSubmit:s[3]||(s[3]=(0,a.D$)(((...e)=>_.submitTicket&&_.submitTicket(...e)),["prevent"]))},[(0,t.Lk)("div",u,[s[7]||(s[7]=(0,t.Lk)("label",null,"Subject *",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[0]||(s[0]=e=>w.subject=e),placeholder:"What do you need help with?",required:""},null,512),[[a.Jo,w.subject]])]),(0,t.Lk)("div",c,[s[9]||(s[9]=(0,t.Lk)("label",null,"Related Listing (optional)",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[1]||(s[1]=e=>w.loungeId=e)},[s[8]||(s[8]=(0,t.Lk)("option",{value:""},"General Question",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(w.lounges,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.id,value:e.id},(0,l.v_)(e.name),9,p)))),128))],512),[[a.u1,w.loungeId]])]),(0,t.Lk)("div",h,[s[10]||(s[10]=(0,t.Lk)("label",null,"Message *",-1)),(0,t.bo)((0,t.Lk)("textarea",{"onUpdate:modelValue":s[2]||(s[2]=e=>w.message=e),rows:"5",placeholder:"Describe your issue or question in detail...",required:""},null,512),[[a.Jo,w.message]])]),w.error?((0,t.uX)(),(0,t.CE)("p",k,(0,l.v_)(w.error),1)):(0,t.Q3)("",!0),(0,t.Lk)("button",{type:"submit",class:"biz-btn",disabled:w.loading},(0,l.v_)(w.loading?"Submitting...":"Submit Ticket"),9,g)],32)])),w.tickets.length?((0,t.uX)(),(0,t.CE)("div",m,[s[15]||(s[15]=(0,t.Lk)("h2",null,"Your Tickets",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(w.tickets,(e=>((0,t.uX)(),(0,t.CE)("div",{key:e.id,class:"ticket-card"},[(0,t.Lk)("div",v,[(0,t.Lk)("strong",null,(0,l.v_)(e.subject),1),(0,t.Lk)("span",{class:(0,l.C4)(["ticket-status",e.status])},(0,l.v_)(e.status),3),(0,t.Lk)("span",L,(0,l.v_)(new Date(e.created_at).toLocaleDateString()),1)]),(0,t.Lk)("p",y,(0,l.v_)(e.message),1),e.admin_response?((0,t.uX)(),(0,t.CE)("div",f,[s[14]||(s[14]=(0,t.Lk)("strong",null,"Response:",-1)),(0,t.Lk)("p",null,(0,l.v_)(e.admin_response),1)])):(0,t.Q3)("",!0)])))),128))])):(0,t.Q3)("",!0)])])}i(4114);var w=i(7465),_={name:"BusinessSupport",data(){return{subject:"",message:"",loungeId:"",lounges:[],tickets:[],loading:!1,submitted:!1,error:null}},computed:{token(){return localStorage.getItem("business_session_token")}},methods:{async loadData(){try{const e=await fetch(w.baseUrl+"api/v1/business/dashboard",{headers:{"Session-Token":this.token}}),s=await e.json();this.lounges=s.lounges||[]}catch(e){console.error(e)}try{const e=await fetch(w.baseUrl+"api/v1/business/support_tickets",{headers:{"Session-Token":this.token}}),s=await e.json();this.tickets=s.tickets||[]}catch(e){console.error(e)}},async submitTicket(){this.error=null,this.loading=!0;try{const e=await fetch(w.baseUrl+"api/v1/business/support",{method:"POST",headers:{"Content-Type":"application/json","Session-Token":this.token},body:JSON.stringify({subject:this.subject,message:this.message,lounge_id:this.loungeId||void 0})}),s=await e.json();e.ok?(this.submitted=!0,this.subject="",this.message="",this.loungeId="",this.loadData()):this.error=s.errors?s.errors.join(", "):"Failed"}catch(e){this.error="Network error"}finally{this.loading=!1}}},mounted(){document.title="Support - CigarFinder Business",this.token?this.loadData():this.$router.push("/business/login")}},F=i(6262);const E=(0,F.A)(_,[["render",C]]);var S=E}}]);
//# sourceMappingURL=business-pages.9f89be7d.js.map