"use strict";(self["webpackChunkcigar_finder_frontend"]=self["webpackChunkcigar_finder_frontend"]||[]).push([[114],{256:function(e,s,i){i.r(s),i.d(s,{default:function(){return ge}});var t=i(641),o=i(33),l=i(3751);const a={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},h={key:0,class:"step-section"},p={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"},y={key:0},L={key:1},f={key:0,class:"method-check"},C={class:"method-info"},w={key:0},_={key:1},E={key:0,class:"method-check"},F={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"],M={key:1},V={key:2,class:"code-input-group"},I=["disabled"],D={key:2,class:"verify-card"},B={key:0,class:"no-website-notice"},O={key:1},Q={class:"meta-code-block"},j=["disabled"],J={key:3,class:"verify-card"},q={key:0,class:"upload-placeholder"},$={key:1,class:"upload-preview"},N=["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"},oe={class:"faq-answer"},le={class:"faq-item"},ae={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,he){const pe=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",a,[ce.lounge?((0,t.uX)(),(0,t.CE)("nav",n,[(0,t.bF)(pe,{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)(pe,{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)(pe,{to:he.cityLink},{default:(0,t.k6)((()=>[(0,t.eW)((0,o.v_)(ce.lounge.city)+", "+(0,o.v_)(ce.lounge.state),1)])),_:1},8,["to"]),s[29]||(s[29]=(0,t.Lk)("span",{class:"sep"},"/",-1)),(0,t.bF)(pe,{to:he.loungeLink},{default:(0,t.k6)((()=>[(0,t.eW)((0,o.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,o.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)(pe,{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",h,[s[52]||(s[52]=(0,t.Lk)("h2",{class:"step-title"},"Choose a verification method",-1)),(0,t.Lk)("div",p,[(0,t.Lk)("div",{class:(0,o.C4)(["method-card",{selected:"phone"===ce.selectedMethod}]),onClick:s[0]||(s[0]=e=>he.selectMethod("phone"))},[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,o.v_)(he.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"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",m,"✓")):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,o.C4)(["method-card",{selected:"domain_email"===ce.selectedMethod}]),onClick:s[1]||(s[1]=e=>he.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",y,[s[42]||(s[42]=(0,t.eW)(" We'll send a code to your email at ")),(0,t.Lk)("strong",null,"@"+(0,o.v_)(he.extractDomain(ce.lounge.website)),1),s[43]||(s[43]=(0,t.eW)(". "))])):((0,t.uX)(),(0,t.CE)("p",L," 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,o.C4)(["method-card",{selected:"website_meta"===ce.selectedMethod}]),onClick:s[2]||(s[2]=e=>he.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,o.v_)(he.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",E,"✓")):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,o.C4)(["method-card",{selected:"manual"===ce.selectedMethod}]),onClick:s[3]||(s[3]=e=>he.selectMethod("manual"))},[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"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",F,"✓")):(0,t.Q3)("",!0)],2)]),(0,t.Lk)("button",{class:"btn-primary",disabled:!ce.selectedMethod,onClick:s[4]||(s[4]=(...e)=>he.submitClaim&&he.submitClaim(...e))}," Continue with "+(0,o.v_)(he.methodLabel),9,S)])):(0,t.Q3)("",!0),"verify"===ce.step?((0,t.uX)(),(0,t.CE)("div",X,["phone"===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,o.v_)(he.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)=>he.verifyClaim&&he.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)=>he.verifyClaim&&he.verifyClaim(...e))},(0,o.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",M,[(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,o.v_)(he.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)=>he.sendEmailCode&&he.sendEmailCode(...e)),disabled:!ce.businessEmail}," Send Code ",8,T)])),ce.emailCodeSent||ce.lounge.website?((0,t.uX)(),(0,t.CE)("div",V,[(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)=>he.verifyClaim&&he.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)=>he.verifyClaim&&he.verifyClaim(...e))},(0,o.v_)(ce.verifying?"Verifying...":"Verify"),9,I)):(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",O,[(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,o.v_)(ce.lounge.website),1),s[66]||(s[66]=(0,t.eW)(":"))]),(0,t.Lk)("div",Q,[(0,t.Lk)("code",null,(0,o.v_)(ce.metaTag),1),(0,t.Lk)("button",{class:"btn-copy",onClick:s[13]||(s[13]=(...e)=>he.copyMeta&&he.copyMeta(...e))},(0,o.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)=>he.verifyClaim&&he.verifyClaim(...e))},(0,o.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)(pe,{to:he.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"===ce.selectedMethod?((0,t.uX)(),(0,t.CE)("div",J,[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)=>he.handleDrop&&he.handleDrop(...e)),["prevent"]))},[(0,t.Lk)("input",{ref:"fileInput",type:"file",accept:".pdf,.jpg,.jpeg,.png",onChange:s[15]||(s[15]=(...e)=>he.handleFile&&he.handleFile(...e)),hidden:""},null,544),ce.uploadedFile?((0,t.uX)(),(0,t.CE)("div",$,[s[70]||(s[70]=(0,t.Lk)("span",null,"📄",-1)),(0,t.Lk)("span",null,(0,o.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)=>he.verifyClaim&&he.verifyClaim(...e))},(0,o.v_)(ce.verifying?"Submitting...":"Submit for Review"),9,N)])):(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,o.v_)("manual"===ce.selectedMethod?"Submission Received":"Verification Successful"),1),"manual"===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,o.v_)(ce.lounge.name),1),s[74]||(s[74]=(0,t.eW)(" listing. "))])),(0,t.bF)(pe,{to:he.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,o.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-a874640e>What you get when you verify</h3><ul class="benefits-list" data-v-a874640e><li data-v-a874640e><span class="check-icon" data-v-a874640e>✓</span> Update your hours, photos, and description </li><li data-v-a874640e><span class="check-icon" data-v-a874640e>✓</span> Respond to customer reviews </li><li data-v-a874640e><span class="check-icon" data-v-a874640e>✓</span> Get a verified badge on your listing </li><li data-v-a874640e><span class="check-icon" data-v-a874640e>✓</span> Add a free backlink to get premium features </li><li data-v-a874640e><span class="check-icon" data-v-a874640e>✓</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=>he.toggleFaq(0))},[s[78]||(s[78]=(0,t.eW)(" How long does verification take? ")),(0,t.Lk)("span",ee,(0,o.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=>he.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,o.v_)(ce.faqOpen[1]?"−":"+"),1)]),(0,t.bo)((0,t.Lk)("div",oe," 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=>he.toggleFaq(2))},[s[80]||(s[80]=(0,t.eW)(" Can multiple people manage one listing? ")),(0,t.Lk)("span",ae,(0,o.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)(pe,{to:"/store-locator",class:"btn-primary"},{default:(0,t.k6)((()=>s[83]||(s[83]=[(0,t.eW)("Back to Store Locator")]))),_:1})]))])}i(8992),i(2577);var ce=i(7465),he={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?per_page=100");this.lounge=(s.lounges||[]).find((s=>s.id==e))||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]}}},pe=i(6262);const ke=(0,pe.A)(he,[["render",ue],["__scopeId","data-v-a874640e"]]);var ge=ke},3432:function(e,s,i){i.r(s),i.d(s,{default:function(){return I}});var t=i(641),o=i(33),l=i(3751);const a={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:"search-claim"},h={key:0,class:"search-results"},p={class:"result-info"},k=["onClick"],g={key:1,class:"already-claimed"},b={key:1,class:"no-results"},m={key:1,class:"lounges-list"},v={class:"lounge-info"},y={key:0,class:"badge-verified"},L={key:1,class:"badge-pending"},f={key:2,class:"badge-featured"},C={class:"lounge-location"},w={class:"lounge-stats"},_={class:"lounge-actions"},E=["onClick"],F={class:"lounge-embed-link"},S={key:2,class:"backlink-section"},X={class:"backlink-actions"},U={key:1,class:"business-container"},W={class:"business-header"},x={key:2,class:"loading"};function z(e,s,i,z,P,T){const M=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",a,[P.user?((0,t.uX)(),(0,t.CE)("div",n,[(0,t.Lk)("div",r,[s[4]||(s[4]=(0,t.Lk)("h1",null,"Business Dashboard",-1)),(0,t.Lk)("p",null,"Welcome, "+(0,o.v_)(P.user.full_name),1),(0,t.Lk)("button",{onClick:s[0]||(s[0]=(...e)=>T.logout&&T.logout(...e)),class:"btn-logout"},"Logout")]),(0,t.Lk)("div",d,[(0,t.bF)(M,{to:"/business/dashboard",class:"dash-link active"},{default:(0,t.k6)((()=>s[5]||(s[5]=[(0,t.eW)("Dashboard")]))),_:1}),(0,t.bF)(M,{to:"/business/subscription",class:"dash-link"},{default:(0,t.k6)((()=>s[6]||(s[6]=[(0,t.eW)("Plans & Billing")]))),_:1}),(0,t.bF)(M,{to:"/business/support",class:"dash-link"},{default:(0,t.k6)((()=>s[7]||(s[7]=[(0,t.eW)("Support")]))),_:1}),(0,t.bF)(M,{to:"/business/profile",class:"dash-link"},{default:(0,t.k6)((()=>s[8]||(s[8]=[(0,t.eW)("My Profile")]))),_:1})]),P.lounges.length||P.loading?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",u,[s[9]||(s[9]=(0,t.Lk)("h2",null,"No Listings Yet",-1)),s[10]||(s[10]=(0,t.Lk)("p",null,"Search for your business below to claim your listing, or browse the Store Locator.",-1)),(0,t.Lk)("div",c,[(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[1]||(s[1]=e=>P.searchQuery=e),placeholder:"Search for your business name...",onKeyup:s[2]||(s[2]=(0,l.jR)(((...e)=>T.searchLounges&&T.searchLounges(...e)),["enter"])),class:"search-input"},null,544),[[l.Jo,P.searchQuery]]),(0,t.Lk)("button",{onClick:s[3]||(s[3]=(...e)=>T.searchLounges&&T.searchLounges(...e)),class:"btn-search"},"Search")]),P.searchResults.length?((0,t.uX)(),(0,t.CE)("div",h,[(0,t.Lk)("h3",null,"Found "+(0,o.v_)(P.searchResults.length)+" matches:",1),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(P.searchResults,(e=>((0,t.uX)(),(0,t.CE)("div",{class:"result-card",key:e.id},[(0,t.Lk)("div",p,[(0,t.Lk)("strong",null,(0,o.v_)(e.name),1),(0,t.Lk)("span",null,(0,o.v_)(e.address)+", "+(0,o.v_)(e.city)+", "+(0,o.v_)(e.state),1)]),e.claimed?((0,t.uX)(),(0,t.CE)("span",g,"Already Claimed")):((0,t.uX)(),(0,t.CE)("button",{key:0,onClick:s=>T.startClaim(e),class:"btn-claim"},"Claim This",8,k))])))),128))])):(0,t.Q3)("",!0),0===P.searchResults.length&&P.searched?((0,t.uX)(),(0,t.CE)("p",b,"No businesses found. Try a different search term.")):(0,t.Q3)("",!0)])),P.lounges.length?((0,t.uX)(),(0,t.CE)("div",m,[(0,t.Lk)("h2",null,"Your Locations ("+(0,o.v_)(P.lounges.length)+")",1),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(P.lounges,(e=>((0,t.uX)(),(0,t.CE)("div",{class:"lounge-dashboard-card",key:e.id},[(0,t.Lk)("div",v,[(0,t.Lk)("h3",null,[(0,t.eW)((0,o.v_)(e.name)+" ",1),e.claimed?((0,t.uX)(),(0,t.CE)("span",y,"Verified")):e.pending_claim?((0,t.uX)(),(0,t.CE)("span",L,"⚠ 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",C,(0,o.v_)(e.city)+", "+(0,o.v_)(e.state),1),(0,t.Lk)("div",w,[(0,t.Lk)("span",null,"Views: "+(0,o.v_)(e.views_count),1),(0,t.Lk)("span",null,"Reviews: "+(0,o.v_)(e.review_count),1),(0,t.Lk)("span",null,"Rating: "+(0,o.v_)(e.rating||"N/A"),1),(0,t.Lk)("span",null,"Tier: "+(0,o.v_)(e.tier),1)])]),(0,t.Lk)("div",_,[(0,t.bF)(M,{to:"/business/lounges/"+e.id+"/edit",class:"btn-action"},{default:(0,t.k6)((()=>s[11]||(s[11]=[(0,t.eW)("Edit Listing")]))),_:2},1032,["to"]),(0,t.bF)(M,{to:"/lounges/"+e.slug,class:"btn-action",target:"_blank"},{default:(0,t.k6)((()=>s[12]||(s[12]=[(0,t.eW)("View Public")]))),_:2},1032,["to"]),(0,t.Lk)("button",{onClick:s=>T.goToSubscription(e.id),class:"btn-action"},"Upgrade",8,E)]),(0,t.Lk)("div",F,[(0,t.bF)(M,{to:"/business/embed-codes",class:"btn-embed"},{default:(0,t.k6)((()=>s[13]||(s[13]=[(0,t.eW)("Get Embed Codes")]))),_:1})])])))),128)),(0,t.bF)(M,{to:"/lounges",class:"btn-add"},{default:(0,t.k6)((()=>s[14]||(s[14]=[(0,t.eW)("+ Claim Another Location")]))),_:1})])):(0,t.Q3)("",!0),P.lounges.length?((0,t.uX)(),(0,t.CE)("div",S,[s[16]||(s[16]=(0,t.Lk)("h3",null,"Backlink Status",-1)),s[17]||(s[17]=(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",X,[(0,t.bF)(M,{to:"/business/embed-codes",class:"btn-action"},{default:(0,t.k6)((()=>s[15]||(s[15]=[(0,t.eW)("Get Embed Codes")]))),_:1})])])):(0,t.Q3)("",!0)])):P.loading?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("div",U,[(0,t.Lk)("div",W,[s[19]||(s[19]=(0,t.Lk)("h1",null,"Business Dashboard",-1)),s[20]||(s[20]=(0,t.Lk)("p",null,"Please log in to manage your listings.",-1)),(0,t.bF)(M,{to:"/business/login",class:"btn-submit",style:{display:"inline-block","margin-top":"16px","text-decoration":"none"}},{default:(0,t.k6)((()=>s[18]||(s[18]=[(0,t.eW)("Log In")]))),_:1})])])),P.loading?((0,t.uX)(),(0,t.CE)("div",x,s[21]||(s[21]=[(0,t.Lk)("p",null,"Loading dashboard...",-1)]))):(0,t.Q3)("",!0)])}i(4114);var P=i(7465),T={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(`${P.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(`${P.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(`${P.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()}},M=i(6262);const V=(0,M.A)(T,[["render",z],["__scopeId","data-v-890363be"]]);var I=V},1872:function(e,s,i){i.r(s),i.d(s,{default:function(){return Gs}});var t=i(641),o=i(33),l=i(3751);const a={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"},h={key:2,class:"edit-success"},p={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"},y={class:"biz-field full"},L=["value"],f={class:"field-row"},C={class:"biz-field"},w={class:"biz-field"},_={class:"field-row three"},E={class:"biz-field"},F={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"},M={class:"toggle-indicator"},V={key:0,class:"expand-hint"},I={class:"section-body"},D={class:"hours-grid"},B={class:"day-label"},O={class:"closed-toggle"},Q=["onUpdate:modelValue"],j=["onUpdate:modelValue"],J=["onUpdate:modelValue"],q={key:1,class:"closed-label"},$={class:"edit-section"},N={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"],oe={key:0,class:"lock-badge"},le={key:0,class:"selected-tags"},ae=["onClick"],ne={key:0,class:"multiselect-placeholder"},re={key:1,class:"multiselect-placeholder"},de={class:"multiselect-dropdown"},ue=["value","disabled"],ce={class:"edit-section"},he={class:"toggle-indicator"},pe={key:0,class:"expand-hint"},ke={class:"section-body"},ge={class:"subsection"},be={class:"toggle-grid"},me={class:"toggle-item"},ve={class:"toggle-item"},ye={class:"toggle-item"},Le={class:"toggle-item"},fe={class:"toggle-item"},Ce={class:"toggle-item"},we={class:"toggle-item"},_e={class:"subsection"},Ee={class:"toggle-grid"},Fe={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"],Me={class:"toggle-item"},Ve={class:"subsection"},Ie={class:"field-row"},De={class:"biz-field"},Be=["value"],Oe={class:"biz-field"},Qe=["value"],je={class:"biz-field full"},Je={class:"tag-select"},qe=["value"],$e={class:"group-label"},Ne={key:0,class:"lock-badge"},Ae={class:"toggle-item"},Re=["disabled"],He={key:0,class:"biz-field full"},Ye=["disabled"],Ge={class:"group-label"},Ke={key:0,class:"lock-badge"},Ze={class:"toggle-item"},es=["disabled"],ss={key:0,class:"toggle-item"},is=["disabled"],ts={class:"toggle-item"},os=["disabled"],ls={class:"edit-section"},as={class:"section-title"},ns={class:"toggle-indicator"},rs={key:0,class:"expand-hint"},ds={class:"section-body"},us={key:0,class:"photos-grid"},cs=["src","alt"],hs=["onClick"],ps={key:1,class:"biz-field"},ks={key:2,class:"field-hint"},gs={class:"section-title"},bs={key:0,class:"lock-badge"},ms={class:"toggle-indicator"},vs={key:0,class:"expand-hint"},ys={class:"section-body"},Ls={class:"biz-field"},fs=["disabled"],Cs={class:"biz-field"},ws=["disabled"],_s={class:"biz-field"},Es=["disabled"],Fs={class:"biz-field"},Ss=["disabled"],Xs={class:"biz-field"},Us=["disabled"],Ws={class:"biz-field"},xs=["disabled"],zs={class:"section-title"},Ps={key:0,class:"lock-badge"},Ts={class:"toggle-indicator"},Ms={key:0,class:"expand-hint"},Vs={class:"section-body"},Is=["onClick"],Ds={class:"field-row"},Bs={class:"biz-field"},Os={class:"biz-field"},Qs={class:"biz-field full"},js={class:"save-section"},Js=["disabled"],qs={key:1,class:"edit-loading"},$s={key:2,class:"edit-loading"};function Ns(e,s,i,Ns,As,Rs){const Hs=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",a,[As.lounge?((0,t.uX)(),(0,t.CE)("div",n,[(0,t.Lk)("div",r,[(0,t.Lk)("h1",null,"Edit Listing: "+(0,o.v_)(As.lounge.name),1),(0,t.bF)(Hs,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[56]||(s[56]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),As.hasChanges?((0,t.uX)(),(0,t.CE)("div",d,[s[57]||(s[57]=(0,t.Lk)("span",null,"You have unsaved changes",-1)),(0,t.Lk)("button",{class:"biz-btn",onClick:s[0]||(s[0]=(...e)=>Rs.saveListing&&Rs.saveListing(...e)),disabled:As.saving},(0,o.v_)(As.saving?"Saving...":"Save Changes"),9,u)])):(0,t.Q3)("",!0),As.lounge&&!As.lounge.claimed?((0,t.uX)(),(0,t.CE)("div",c,[s[59]||(s[59]=(0,t.Lk)("strong",null,"⚠ Verification Pending",-1)),s[60]||(s[60]=(0,t.Lk)("p",null,"You can edit your listing now. Your changes will go live once verification is complete.",-1)),(0,t.bF)(Hs,{to:"/business/claim/"+As.lounge.id},{default:(0,t.k6)((()=>s[58]||(s[58]=[(0,t.eW)("Complete Verification →")]))),_:1},8,["to"])])):(0,t.Q3)("",!0),As.saveMsg?((0,t.uX)(),(0,t.CE)("p",h,(0,o.v_)(As.saveMsg),1)):(0,t.Q3)("",!0),As.error?((0,t.uX)(),(0,t.CE)("p",p,(0,o.v_)(As.error),1)):(0,t.Q3)("",!0),(0,t.Lk)("div",k,[(0,t.Lk)("h2",{onClick:s[1]||(s[1]=e=>Rs.toggleSection("basic")),class:"section-toggle"},[s[62]||(s[62]=(0,t.Lk)("span",{class:"section-title"},"Basic Information",-1)),(0,t.Lk)("span",g,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.basic}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[61]||(s[61]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),As.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",y,[s[63]||(s[63]=(0,t.Lk)("label",null,"Business Name",-1)),(0,t.Lk)("input",{type:"text",value:As.lounge.name,disabled:"",class:"disabled-input"},null,8,L),s[64]||(s[64]=(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[65]||(s[65]=(0,t.Lk)("label",null,"Address",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[2]||(s[2]=e=>As.form.address_line1=e),placeholder:"Street address"},null,512),[[l.Jo,As.form.address_line1]])]),(0,t.Lk)("div",w,[s[66]||(s[66]=(0,t.Lk)("label",null,"Suite / Unit",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[3]||(s[3]=e=>As.form.address_line2=e),placeholder:"Suite, unit, floor"},null,512),[[l.Jo,As.form.address_line2]])])]),(0,t.Lk)("div",_,[(0,t.Lk)("div",E,[s[67]||(s[67]=(0,t.Lk)("label",null,"City",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[4]||(s[4]=e=>As.form.city=e)},null,512),[[l.Jo,As.form.city]])]),(0,t.Lk)("div",F,[s[68]||(s[68]=(0,t.Lk)("label",null,"State",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[5]||(s[5]=e=>As.form.state=e),maxlength:"2",placeholder:"FL"},null,512),[[l.Jo,As.form.state]])]),(0,t.Lk)("div",S,[s[69]||(s[69]=(0,t.Lk)("label",null,"Zip Code",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[6]||(s[6]=e=>As.form.zip_code=e),maxlength:"10"},null,512),[[l.Jo,As.form.zip_code]])])]),(0,t.Lk)("div",X,[(0,t.Lk)("div",U,[s[70]||(s[70]=(0,t.Lk)("label",null,"Phone",-1)),(0,t.bo)((0,t.Lk)("input",{type:"tel","onUpdate:modelValue":s[7]||(s[7]=e=>As.form.phone=e),placeholder:"+1 (555) 123-4567"},null,512),[[l.Jo,As.form.phone]])]),(0,t.Lk)("div",W,[s[71]||(s[71]=(0,t.Lk)("label",null,"Email",-1)),(0,t.bo)((0,t.Lk)("input",{type:"email","onUpdate:modelValue":s[8]||(s[8]=e=>As.form.email=e),placeholder:"info@yourbusiness.com"},null,512),[[l.Jo,As.form.email]])])]),(0,t.Lk)("div",x,[(0,t.Lk)("div",z,[s[72]||(s[72]=(0,t.Lk)("label",null,"Website",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[9]||(s[9]=e=>As.form.website=e),placeholder:"https://yourbusiness.com"},null,512),[[l.Jo,As.form.website]])])]),(0,t.Lk)("div",P,[s[74]||(s[74]=(0,t.Lk)("label",null,"Business Type",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[10]||(s[10]=e=>As.form.lounge_type=e)},s[73]||(s[73]=[(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,As.form.lounge_type]])])],512),[[l.aG,As.sections.basic]])]),(0,t.Lk)("div",T,[(0,t.Lk)("h2",{onClick:s[11]||(s[11]=e=>Rs.toggleSection("hours")),class:"section-toggle"},[s[76]||(s[76]=(0,t.Lk)("span",{class:"section-title"},"Business Hours",-1)),(0,t.Lk)("span",M,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.hours}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[75]||(s[75]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),As.sections.hours?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",V,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",I,[s[79]||(s[79]=(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)(As.dayOrder,(e=>((0,t.uX)(),(0,t.CE)("div",{key:e,class:(0,o.C4)(["hours-row",{"row-closed":As.hoursClosed[e]}])},[(0,t.Lk)("label",B,(0,o.v_)(As.dayNames[e]),1),(0,t.Lk)("label",O,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s=>As.hoursClosed[e]=s},null,8,Q),[[l.lH,As.hoursClosed[e]]]),s[77]||(s[77]=(0,t.eW)(" Closed "))]),As.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=>As.hoursOpen[e]=s,class:"time-input"},null,8,j),[[l.Jo,As.hoursOpen[e]]]),s[78]||(s[78]=(0,t.Lk)("span",{class:"time-sep"},"to",-1)),(0,t.bo)((0,t.Lk)("input",{type:"time","onUpdate:modelValue":s=>As.hoursClose[e]=s,class:"time-input"},null,8,J),[[l.Jo,As.hoursClose[e]]])],64))],2)))),128))])],512),[[l.aG,As.sections.hours]])]),(0,t.Lk)("div",$,[(0,t.Lk)("h2",{onClick:s[12]||(s[12]=e=>Rs.toggleSection("about")),class:"section-toggle"},[s[81]||(s[81]=(0,t.Lk)("span",{class:"section-title"},"About Your Business",-1)),(0,t.Lk)("span",N,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.about}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[80]||(s[80]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),As.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[82]||(s[82]=(0,t.Lk)("label",null,"Description",-1)),(0,t.bo)((0,t.Lk)("textarea",{"onUpdate:modelValue":s[13]||(s[13]=e=>As.form.description=e),rows:"5",placeholder:"Tell customers about your business, what makes it special, your history..."},null,512),[[l.Jo,As.form.description]])]),(0,t.Lk)("div",{class:(0,o.C4)(["checkbox-group",{locked:!Rs.canEditIdentity}])},[(0,t.Lk)("label",Y,[s[83]||(s[83]=(0,t.eW)("Business Identity ")),Rs.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=>As.identityForm.women_owned=e),disabled:!Rs.canEditIdentity},null,8,Z),[[l.lH,As.identityForm.women_owned]]),s[84]||(s[84]=(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=>As.identityForm.minority_owned=e),disabled:!Rs.canEditIdentity},null,8,se),[[l.lH,As.identityForm.minority_owned]]),s[85]||(s[85]=(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=>As.identityForm.veteran_owned=e),disabled:!Rs.canEditIdentity},null,8,te),[[l.lH,As.identityForm.veteran_owned]]),s[86]||(s[86]=(0,t.eW)(" Veteran Owned & Operated"))])],2),(0,t.Lk)("div",{class:(0,o.C4)(["biz-field full",{locked:!Rs.canEditIdentity}])},[(0,t.Lk)("label",null,[s[87]||(s[87]=(0,t.eW)("Languages Spoken ")),Rs.canEditIdentity?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",oe,"Featured Only"))]),(0,t.Lk)("div",{class:(0,o.C4)(["language-multiselect",{disabled:!Rs.canEditIdentity}])},[As.identityForm.languages.length?((0,t.uX)(),(0,t.CE)("div",le,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.identityForm.languages,(e=>((0,t.uX)(),(0,t.CE)("span",{class:"lang-tag",key:e},[(0,t.eW)((0,o.v_)(e)+" ",1),Rs.canEditIdentity?((0,t.uX)(),(0,t.CE)("button",{key:0,type:"button",class:"tag-remove",onClick:s=>Rs.removeLanguage(e)},"×",8,ae)):(0,t.Q3)("",!0)])))),128))])):(0,t.Q3)("",!0),(0,t.Lk)("div",{class:(0,o.C4)(["multiselect-trigger",{active:As.languageDropdownOpen}]),onClick:s[17]||(s[17]=(...e)=>Rs.toggleLanguageDropdown&&Rs.toggleLanguageDropdown(...e))},[As.identityForm.languages.length?((0,t.uX)(),(0,t.CE)("span",re,(0,o.v_)(As.identityForm.languages.length)+" selected",1)):((0,t.uX)(),(0,t.CE)("span",ne,"Select languages...")),((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.languageDropdownOpen}]),width:"14",height:"14",viewBox:"0 0 16 16",fill:"none"},s[88]||(s[88]=[(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)(As.languageOptions,(e=>((0,t.uX)(),(0,t.CE)("label",{key:e,class:(0,o.C4)(["dropdown-check-item",{selected:As.identityForm.languages.includes(e)}])},[(0,t.bo)((0,t.Lk)("input",{type:"checkbox",value:e,"onUpdate:modelValue":s[18]||(s[18]=e=>As.identityForm.languages=e),disabled:!Rs.canEditIdentity},null,8,ue),[[l.lH,As.identityForm.languages]]),(0,t.Lk)("span",null,(0,o.v_)(e),1)],2)))),128))],512),[[l.aG,As.languageDropdownOpen]])],2)],2)],512),[[l.aG,As.sections.about]])]),(0,t.Lk)("div",ce,[(0,t.Lk)("h2",{onClick:s[19]||(s[19]=e=>Rs.toggleSection("features")),class:"section-toggle"},[s[90]||(s[90]=(0,t.Lk)("span",{class:"section-title"},"Features & Amenities",-1)),(0,t.Lk)("span",he,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.features}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[89]||(s[89]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),As.sections.features?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",pe,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",ke,[(0,t.Lk)("div",ge,[s[98]||(s[98]=(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=>As.amenitiesForm.lounge_area=e)},null,512),[[l.lH,As.amenitiesForm.lounge_area]]),s[91]||(s[91]=(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=>As.amenitiesForm.wifi=e)},null,512),[[l.lH,As.amenitiesForm.wifi]]),s[92]||(s[92]=(0,t.eW)(" Wi-Fi"))]),(0,t.Lk)("label",ye,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[22]||(s[22]=e=>As.amenitiesForm.tv=e)},null,512),[[l.lH,As.amenitiesForm.tv]]),s[93]||(s[93]=(0,t.eW)(" TV"))]),(0,t.Lk)("label",Le,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[23]||(s[23]=e=>As.amenitiesForm.parking=e)},null,512),[[l.lH,As.amenitiesForm.parking]]),s[94]||(s[94]=(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=>As.amenitiesForm.outdoor=e)},null,512),[[l.lH,As.amenitiesForm.outdoor]]),s[95]||(s[95]=(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=>As.amenitiesForm.events=e)},null,512),[[l.lH,As.amenitiesForm.events]]),s[96]||(s[96]=(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=>As.amenitiesForm.private_lockers=e)},null,512),[[l.lH,As.amenitiesForm.private_lockers]]),s[97]||(s[97]=(0,t.eW)(" Private Lockers"))])])]),(0,t.Lk)("div",_e,[s[102]||(s[102]=(0,t.Lk)("label",{class:"group-label"},"Cigar Features",-1)),(0,t.Lk)("div",Ee,[(0,t.Lk)("label",Fe,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[27]||(s[27]=e=>As.featuresForm.walk_in_humidor=e)},null,512),[[l.lH,As.featuresForm.walk_in_humidor]]),s[99]||(s[99]=(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=>As.featuresForm.smoke_inside=e)},null,512),[[l.lH,As.featuresForm.smoke_inside]]),s[100]||(s[100]=(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=>As.featuresForm.handroll_service=e)},null,512),[[l.lH,As.featuresForm.handroll_service]]),s[101]||(s[101]=(0,t.eW)(" Handroll / Rolling Service"))])])]),(0,t.Lk)("div",Ue,[s[108]||(s[108]=(0,t.Lk)("label",{class:"group-label"},"Food & Drink",-1)),(0,t.Lk)("div",We,[(0,t.Lk)("div",xe,[s[104]||(s[104]=(0,t.Lk)("label",null,"Bar Type",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[30]||(s[30]=e=>As.featuresForm.bar_type=e)},[s[103]||(s[103]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.options.bar_types,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,o.v_)(e.label),9,ze)))),128))],512),[[l.u1,As.featuresForm.bar_type]])]),(0,t.Lk)("div",Pe,[s[106]||(s[106]=(0,t.Lk)("label",null,"Food",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[31]||(s[31]=e=>As.featuresForm.food_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)(As.options.food_types,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,o.v_)(e.label),9,Te)))),128))],512),[[l.u1,As.featuresForm.food_type]])])]),(0,t.Lk)("label",Me,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[32]||(s[32]=e=>As.featuresForm.gambling_gaming=e)},null,512),[[l.lH,As.featuresForm.gambling_gaming]]),s[107]||(s[107]=(0,t.eW)(" Gambling / Gaming"))])]),(0,t.Lk)("div",Ve,[s[114]||(s[114]=(0,t.Lk)("label",{class:"group-label"},"Atmosphere",-1)),(0,t.Lk)("div",Ie,[(0,t.Lk)("div",De,[s[110]||(s[110]=(0,t.Lk)("label",null,"Located In",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[33]||(s[33]=e=>As.featuresForm.located_in=e)},[s[109]||(s[109]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.options.located_in,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,o.v_)(e.label),9,Be)))),128))],512),[[l.u1,As.featuresForm.located_in]])]),(0,t.Lk)("div",Oe,[s[112]||(s[112]=(0,t.Lk)("label",null,"Dress Code",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[34]||(s[34]=e=>As.featuresForm.dress_code=e)},[s[111]||(s[111]=(0,t.Lk)("option",{value:""},"Select...",-1)),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.options.dress_codes,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.value,value:e.value},(0,o.v_)(e.label),9,Qe)))),128))],512),[[l.u1,As.featuresForm.dress_code]])])]),(0,t.Lk)("div",je,[s[113]||(s[113]=(0,t.Lk)("label",null,"Atmosphere (select all that apply)",-1)),(0,t.Lk)("div",Je,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.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[35]||(s[35]=e=>As.featuresForm.atmosphere=e)},null,8,qe),[[l.lH,As.featuresForm.atmosphere]]),(0,t.eW)(" "+(0,o.v_)(e.label),1)])))),128))])])]),(0,t.Lk)("div",{class:(0,o.C4)(["subsection",{locked:!Rs.isFeatured}])},[(0,t.Lk)("label",$e,[s[115]||(s[115]=(0,t.eW)("Entertainment ")),Rs.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Ne,"Featured Only"))]),(0,t.Lk)("label",Ae,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[36]||(s[36]=e=>As.featuresForm.live_entertainment=e),disabled:!Rs.isFeatured},null,8,Re),[[l.lH,As.featuresForm.live_entertainment]]),s[116]||(s[116]=(0,t.eW)(" Live Entertainment"))]),As.featuresForm.live_entertainment?((0,t.uX)(),(0,t.CE)("div",He,[s[117]||(s[117]=(0,t.Lk)("label",null,"Entertainment Schedule URL",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[37]||(s[37]=e=>As.featuresForm.entertainment_schedule_url=e),placeholder:"https://yourbusiness.com/events",disabled:!Rs.isFeatured},null,8,Ye),[[l.Jo,As.featuresForm.entertainment_schedule_url]])])):(0,t.Q3)("",!0)],2),(0,t.Lk)("div",{class:(0,o.C4)(["subsection",{locked:!Rs.isFeatured}])},[(0,t.Lk)("label",Ge,[s[118]||(s[118]=(0,t.eW)("Membership ")),Rs.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Ke,"Featured Only"))]),(0,t.Lk)("label",Ze,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[38]||(s[38]=e=>As.featuresForm.private_membership=e),disabled:!Rs.isFeatured},null,8,es),[[l.lH,As.featuresForm.private_membership]]),s[119]||(s[119]=(0,t.eW)(" Private Lounge Membership"))]),As.featuresForm.private_membership?((0,t.uX)(),(0,t.CE)("label",ss,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[39]||(s[39]=e=>As.featuresForm.twenty_four_hour_access=e),disabled:!Rs.isFeatured},null,8,is),[[l.lH,As.featuresForm.twenty_four_hour_access]]),s[120]||(s[120]=(0,t.eW)(" 24 Hour Access"))])):(0,t.Q3)("",!0),(0,t.Lk)("label",ts,[(0,t.bo)((0,t.Lk)("input",{type:"checkbox","onUpdate:modelValue":s[40]||(s[40]=e=>As.featuresForm.work_desk=e),disabled:!Rs.isFeatured},null,8,os),[[l.lH,As.featuresForm.work_desk]]),s[121]||(s[121]=(0,t.eW)(" Work Desk / Computer Area"))])],2)],512),[[l.aG,As.sections.features]])]),(0,t.Lk)("div",ls,[(0,t.Lk)("h2",{onClick:s[41]||(s[41]=e=>Rs.toggleSection("photos")),class:"section-toggle"},[(0,t.Lk)("span",as,"Photos ("+(0,o.v_)(As.lounge.photos?As.lounge.photos.length:0)+" / "+(0,o.v_)(As.lounge.max_photos||1)+")",1),(0,t.Lk)("span",ns,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.photos}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[122]||(s[122]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),As.sections.photos?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",rs,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",ds,[As.lounge.photos&&As.lounge.photos.length?((0,t.uX)(),(0,t.CE)("div",us,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.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,cs),(0,t.Lk)("button",{class:"photo-delete",onClick:s=>Rs.deletePhoto(e.id)},"×",8,hs)])))),128))])):(0,t.Q3)("",!0),(As.lounge.photos||[]).length<(As.lounge.max_photos||1)?((0,t.uX)(),(0,t.CE)("div",ps,[s[123]||(s[123]=(0,t.Lk)("label",null,"Upload Photo",-1)),(0,t.Lk)("input",{type:"file",onChange:s[42]||(s[42]=(...e)=>Rs.uploadPhoto&&Rs.uploadPhoto(...e)),accept:"image/*",ref:"photoInput"},null,544)])):((0,t.uX)(),(0,t.CE)("p",ks,[s[125]||(s[125]=(0,t.eW)("Maximum photos reached for your tier. ")),(0,t.bF)(Hs,{to:"/business/subscription"},{default:(0,t.k6)((()=>s[124]||(s[124]=[(0,t.eW)("Upgrade for more →")]))),_:1})]))],512),[[l.aG,As.sections.photos]])]),(0,t.Lk)("div",{class:(0,o.C4)(["edit-section",{locked:!Rs.isFeatured}])},[(0,t.Lk)("h2",{onClick:s[43]||(s[43]=e=>Rs.toggleSection("social")),class:"section-toggle"},[(0,t.Lk)("span",gs,[s[126]||(s[126]=(0,t.eW)("Social Profiles ")),Rs.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",bs,"Featured Only"))]),(0,t.Lk)("span",ms,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.social}]),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)),As.sections.social?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",vs,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",ys,[(0,t.Lk)("div",Ls,[s[128]||(s[128]=(0,t.Lk)("label",null,"Facebook",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[44]||(s[44]=e=>As.socialForm.facebook=e),placeholder:"https://facebook.com/yourbusiness",disabled:!Rs.isFeatured},null,8,fs),[[l.Jo,As.socialForm.facebook]])]),(0,t.Lk)("div",Cs,[s[129]||(s[129]=(0,t.Lk)("label",null,"Instagram",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[45]||(s[45]=e=>As.socialForm.instagram=e),placeholder:"https://instagram.com/yourbusiness",disabled:!Rs.isFeatured},null,8,ws),[[l.Jo,As.socialForm.instagram]])]),(0,t.Lk)("div",_s,[s[130]||(s[130]=(0,t.Lk)("label",null,"TikTok",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[46]||(s[46]=e=>As.socialForm.tiktok=e),placeholder:"https://tiktok.com/@yourbusiness",disabled:!Rs.isFeatured},null,8,Es),[[l.Jo,As.socialForm.tiktok]])]),(0,t.Lk)("div",Fs,[s[131]||(s[131]=(0,t.Lk)("label",null,"YouTube",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[47]||(s[47]=e=>As.socialForm.youtube=e),placeholder:"https://youtube.com/@yourbusiness",disabled:!Rs.isFeatured},null,8,Ss),[[l.Jo,As.socialForm.youtube]])]),(0,t.Lk)("div",Xs,[s[132]||(s[132]=(0,t.Lk)("label",null,"LinkedIn",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[48]||(s[48]=e=>As.socialForm.linkedin=e),placeholder:"https://linkedin.com/company/yourbusiness",disabled:!Rs.isFeatured},null,8,Us),[[l.Jo,As.socialForm.linkedin]])]),(0,t.Lk)("div",Ws,[s[133]||(s[133]=(0,t.Lk)("label",null,"Twitter / X",-1)),(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[49]||(s[49]=e=>As.socialForm.twitter=e),placeholder:"https://x.com/yourbusiness",disabled:!Rs.isFeatured},null,8,xs),[[l.Jo,As.socialForm.twitter]])])],512),[[l.aG,As.sections.social]])],2),(0,t.Lk)("div",{class:(0,o.C4)(["edit-section",{locked:!Rs.isFeatured}])},[(0,t.Lk)("h2",{onClick:s[50]||(s[50]=e=>Rs.toggleSection("events")),class:"section-toggle"},[(0,t.Lk)("span",zs,[s[134]||(s[134]=(0,t.eW)("Events ")),Rs.isFeatured?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Ps,"Featured Only"))]),(0,t.Lk)("span",Ts,[((0,t.uX)(),(0,t.CE)("svg",{class:(0,o.C4)(["chevron-icon",{open:As.sections.events}]),width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},s[135]||(s[135]=[(0,t.Lk)("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]),2)),As.sections.events?(0,t.Q3)("",!0):((0,t.uX)(),(0,t.CE)("span",Ms,"Click to expand"))])]),(0,t.bo)((0,t.Lk)("div",Vs,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(As.lounge.events,(e=>((0,t.uX)(),(0,t.CE)("div",{key:e.id,class:"event-item"},[(0,t.Lk)("strong",null,(0,o.v_)(e.title),1),(0,t.eW)(" — "+(0,o.v_)(new Date(e.event_date).toLocaleDateString())+" ",1),(0,t.Lk)("button",{class:"small-delete",onClick:s=>Rs.deleteEvent(e.id)},"Remove",8,Is)])))),128)),s[139]||(s[139]=(0,t.Lk)("h3",{class:"mt-16"},"Add Event",-1)),(0,t.Lk)("div",Ds,[(0,t.Lk)("div",Bs,[s[136]||(s[136]=(0,t.Lk)("label",null,"Title",-1)),(0,t.bo)((0,t.Lk)("input",{type:"text","onUpdate:modelValue":s[51]||(s[51]=e=>As.newEvent.title=e),placeholder:"Cigar & Whiskey Night"},null,512),[[l.Jo,As.newEvent.title]])]),(0,t.Lk)("div",Os,[s[137]||(s[137]=(0,t.Lk)("label",null,"Date",-1)),(0,t.bo)((0,t.Lk)("input",{type:"datetime-local","onUpdate:modelValue":s[52]||(s[52]=e=>As.newEvent.event_date=e)},null,512),[[l.Jo,As.newEvent.event_date]])])]),(0,t.Lk)("div",Qs,[s[138]||(s[138]=(0,t.Lk)("label",null,"Description",-1)),(0,t.bo)((0,t.Lk)("textarea",{"onUpdate:modelValue":s[53]||(s[53]=e=>As.newEvent.description=e),rows:"2",placeholder:"Details about the event..."},null,512),[[l.Jo,As.newEvent.description]])]),(0,t.Lk)("button",{class:"biz-btn-sm",onClick:s[54]||(s[54]=(...e)=>Rs.addEvent&&Rs.addEvent(...e))},"Add Event")],512),[[l.aG,As.sections.events&&Rs.isFeatured]])],2),(0,t.Lk)("div",js,[(0,t.Lk)("button",{class:"biz-btn",onClick:s[55]||(s[55]=(...e)=>Rs.saveListing&&Rs.saveListing(...e)),disabled:As.saving},(0,o.v_)(As.saving?"Saving...":"Save All Changes"),9,Js),(0,t.bF)(Hs,{to:"/lounges/"+As.lounge.slug,class:"view-link",target:"_blank"},{default:(0,t.k6)((()=>s[140]||(s[140]=[(0,t.eW)("View Public Listing →")]))),_:1},8,["to"])])])):As.loading?((0,t.uX)(),(0,t.CE)("div",qs,s[141]||(s[141]=[(0,t.Lk)("p",null,"Loading listing...",-1)]))):((0,t.uX)(),(0,t.CE)("div",$s,s[142]||(s[142]=[(0,t.Lk)("p",null,"Listing not found or you don't have access.",-1)])))])}i(4114),i(8992),i(4520),i(3949);var As=i(7465),Rs={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},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(As.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 o=e.social_links||{};Object.keys(this.socialForm).forEach((e=>{this.socialForm[e]=o[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(As.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(As.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(As.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(As.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(As.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,As.fetchData)(As.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)}},Hs=i(6262);const Ys=(0,Hs.A)(Rs,[["render",Ns]]);var Gs=Ys},8953:function(e,s,i){i.r(s),i.d(s,{default:function(){return P}});var t=i(641),o=i(33),l=i(3751);const a={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"}},h={key:3},p={key:0,class:"lounge-select"},k=["value"],g={class:"embed-option"},b={class:"code-box"},m={class:"embed-option"},v={class:"size-tabs"},y=["onClick"],L={class:"code-box"},f={class:"embed-option"},C={class:"code-box"},w={class:"embed-option"},_={class:"code-box"},E={class:"verify-section"},F={class:"verify-row"},S=["disabled"];function X(e,s,i,X,U,W){const x=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",a,[(0,t.Lk)("div",n,[(0,t.Lk)("div",r,[s[9]||(s[9]=(0,t.Lk)("h1",null,"Get Your CigarFinder Badge",-1)),s[10]||(s[10]=(0,t.Lk)("p",null,"Add one of these to your website to keep your listing active. Choose the option that works best for your site.",-1)),(0,t.bF)(x,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[8]||(s[8]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),W.isLoggedIn?U.loading?((0,t.uX)(),(0,t.CE)("div",u,s[14]||(s[14]=[(0,t.Lk)("p",null,"Loading your listings...",-1)]))):0===U.lounges.length?((0,t.uX)(),(0,t.CE)("div",c,[(0,t.Lk)("p",null,[s[16]||(s[16]=(0,t.eW)("You need to ")),(0,t.bF)(x,{to:"/lounges"},{default:(0,t.k6)((()=>s[15]||(s[15]=[(0,t.eW)("claim a listing")]))),_:1}),s[17]||(s[17]=(0,t.eW)(" first to get embed codes."))])])):((0,t.uX)(),(0,t.CE)("div",h,[U.lounges.length>1?((0,t.uX)(),(0,t.CE)("div",p,[s[18]||(s[18]=(0,t.Lk)("label",null,"Select listing:",-1)),(0,t.bo)((0,t.Lk)("select",{"onUpdate:modelValue":s[0]||(s[0]=e=>U.selectedLoungeId=e),onChange:s[1]||(s[1]=(...e)=>W.loadEmbedCodes&&W.loadEmbedCodes(...e))},[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(U.lounges,(e=>((0,t.uX)(),(0,t.CE)("option",{key:e.id,value:e.id},(0,o.v_)(e.name)+" - "+(0,o.v_)(e.city)+", "+(0,o.v_)(e.state),9,k)))),128))],544),[[l.u1,U.selectedLoungeId]])])):(0,t.Q3)("",!0),(0,t.Lk)("div",g,[s[19]||(s[19]=(0,t.Lk)("h2",null,"1. Simple Text Link",-1)),s[20]||(s[20]=(0,t.Lk)("p",{class:"embed-desc"},"One line of HTML. Add to your website footer, sidebar, or partners page.",-1)),s[21]||(s[21]=(0,t.Lk)("div",{class:"embed-preview"},[(0,t.Lk)("a",{href:"#",style:{color:"#B26D28","text-decoration":"none","font-weight":"600"}},"Find us on CigarFinder - Compare Cigar Prices")],-1)),(0,t.Lk)("div",b,[(0,t.Lk)("code",null,(0,o.v_)(W.textLinkCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[2]||(s[2]=e=>W.copyCode(W.textLinkCode,"text"))},(0,o.v_)("text"===U.copied?"Copied!":"Copy Code"),1)])]),(0,t.Lk)("div",m,[s[22]||(s[22]=(0,t.Lk)("h2",null,"2. Badge Image",-1)),s[23]||(s[23]=(0,t.Lk)("p",{class:"embed-desc"},"A visual badge with a link back to your listing. Choose a size:",-1)),(0,t.Lk)("div",v,[((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(U.badgeSizes,(e=>((0,t.uX)(),(0,t.CE)("button",{key:e.key,onClick:s=>U.selectedSize=e.key,class:(0,o.C4)([{active:U.selectedSize===e.key},"size-tab"])},(0,o.v_)(e.label),11,y)))),128))]),(0,t.Lk)("div",L,[(0,t.Lk)("code",null,(0,o.v_)(W.badgeCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[3]||(s[3]=e=>W.copyCode(W.badgeCode,"badge"))},(0,o.v_)("badge"===U.copied?"Copied!":"Copy Code"),1)])]),(0,t.Lk)("div",f,[s[24]||(s[24]=(0,t.Lk)("h2",null,"3. Live Widget",-1)),s[25]||(s[25]=(0,t.Lk)("p",{class:"embed-desc"},"A dynamic badge that auto-updates with your rating and review count.",-1)),(0,t.Lk)("div",C,[(0,t.Lk)("code",null,(0,o.v_)(W.widgetCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[4]||(s[4]=e=>W.copyCode(W.widgetCode,"widget"))},(0,o.v_)("widget"===U.copied?"Copied!":"Copy Code"),1)])]),(0,t.Lk)("div",w,[s[26]||(s[26]=(0,t.Lk)("h2",null,"4. iframe Embed",-1)),s[27]||(s[27]=(0,t.Lk)("p",{class:"embed-desc"},"For sites that block external JavaScript.",-1)),(0,t.Lk)("div",_,[(0,t.Lk)("code",null,(0,o.v_)(W.iframeCode),1),(0,t.Lk)("button",{class:"copy-btn",onClick:s[5]||(s[5]=e=>W.copyCode(W.iframeCode,"iframe"))},(0,o.v_)("iframe"===U.copied?"Copied!":"Copy Code"),1)])]),(0,t.Lk)("div",E,[s[28]||(s[28]=(0,t.Lk)("h2",null,"Verify Your Backlink",-1)),s[29]||(s[29]=(0,t.Lk)("p",null,"After adding the code to your site, enter the page URL and click verify:",-1)),(0,t.Lk)("div",F,[(0,t.bo)((0,t.Lk)("input",{type:"url","onUpdate:modelValue":s[6]||(s[6]=e=>U.verifyUrl=e),placeholder:"https://yoursite.com/page-with-badge",class:"verify-input"},null,512),[[l.Jo,U.verifyUrl]]),(0,t.Lk)("button",{class:"biz-btn",onClick:s[7]||(s[7]=(...e)=>W.verifyBacklink&&W.verifyBacklink(...e)),disabled:U.verifying},(0,o.v_)(U.verifying?"Checking...":"Verify"),9,S)]),U.verifyResult?((0,t.uX)(),(0,t.CE)("p",{key:0,class:(0,o.C4)(U.verifyResult.success?"verify-success":"verify-fail")},(0,o.v_)(U.verifyResult.message),3)):(0,t.Q3)("",!0)])])):((0,t.uX)(),(0,t.CE)("div",d,[(0,t.Lk)("p",null,[s[12]||(s[12]=(0,t.eW)("Please ")),(0,t.bF)(x,{to:"/business/login"},{default:(0,t.k6)((()=>s[11]||(s[11]=[(0,t.eW)("log in")]))),_:1}),s[13]||(s[13]=(0,t.eW)(" to view your embed codes."))])]))])])}i(8992),i(2577);var U=i(7465),W={name:"BusinessEmbedCodes",data(){return{lounges:[],selectedLoungeId:null,loading:!0,selectedSize:"small",copied:null,verifyUrl:"",verifying:!1,verifyResult:null,badgeSizes:[{key:"small",label:"150x50"},{key:"medium",label:"300x100"},{key:"leaderboard",label:"728x90"},{key:"rectangle",label:"300x250"}]}},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 '+this.loungeName+" on CigarFinder - Compare Cigar Prices</a>"},badgeCode(){const 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>'}},methods:{async loadDashboard(){this.loading=!0;try{const e=await fetch(U.baseUrl+"api/v1/business/dashboard",{headers:{"Session-Token":this.token}});if(!e.ok)return void(this.loading=!1);const s=await e.json();this.lounges=s.lounges||[],this.lounges.length&&(this.selectedLoungeId=this.lounges[0].id)}catch(e){console.error(e)}this.loading=!1},async loadEmbedCodes(){},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{const e=await fetch(U.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(e){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}},x=i(6262);const z=(0,x.A)(W,[["render",X]]);var P=z},5129:function(e,s,i){i.r(s),i.d(s,{default:function(){return L}});i(4114);var t=i(641),o=i(3751),l=i(33);const a={class:"biz-page"},n={class:"biz-container"},r={class:"biz-card"},d={class:"biz-sub"},u={class:"biz-field"},c={class:"biz-field"},h={key:0,class:"biz-error"},p=["disabled"],k={class:"biz-forgot"};function g(e,s,i,g,b,m){return(0,t.uX)(),(0,t.CE)("div",a,[(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,o.D$)((s=>e.$router.push("/business/register")),["prevent"])),class:"biz-link"},"Create one")]),(0,t.Lk)("form",{onSubmit:s[3]||(s[3]=(0,o.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),[[o.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),[[o.Jo,b.password]])]),b.error?((0,t.uX)(),(0,t.CE)("p",h,(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,p)],32),(0,t.Lk)("p",k,[(0,t.Lk)("a",{onClick:s[4]||(s[4]=(0,o.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 y=(0,v.A)(m,[["render",g]]);var L=y},1206:function(e,s,i){i.r(s),i.d(s,{default:function(){return x}});var t=i(641),o=i(3751),l=i(33);const a={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"},h=["value"],p={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"},y={key:0,class:"biz-error"},L={key:1,class:"edit-success"},f=["disabled"],C={class:"biz-card",style:{"margin-top":"16px"}},w={class:"status-row"},_={class:"status-row"},E={class:"status-row"};function F(e,s,i,F,S,X){const U=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",a,[(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,o.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),[[o.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,h),s[10]||(s[10]=(0,t.Lk)("span",{class:"field-hint"},"Contact support to change your email",-1))]),(0,t.Lk)("div",p,[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),[[o.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,o.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),[[o.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),[[o.Jo,S.confirmPassword]])]),S.pwError?((0,t.uX)(),(0,t.CE)("p",y,(0,l.v_)(S.pwError),1)):(0,t.Q3)("",!0),S.pwSaved?((0,t.uX)(),(0,t.CE)("p",L,"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",E,[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",F]]);var x=W},4016:function(e,s,i){i.r(s),i.d(s,{default:function(){return E}});i(4114);var t=i(641),o=i(3751),l=i(33);const a={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"},h={class:"biz-field"},p={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"}},y={style:{color:"#bbb","margin-bottom":"16px"}};function L(e,s,i,L,f,C){return(0,t.uX)(),(0,t.CE)("div",a,[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",y,"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,o.D$)((s=>e.$router.push("/business/login")),["prevent"])),class:"biz-link"},"Log in")]),(0,t.Lk)("form",{onSubmit:s[6]||(s[6]=(0,o.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),[[o.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),[[o.Jo,f.form.email]])]),(0,t.Lk)("div",h,[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),[[o.Jo,f.form.phone]])]),(0,t.Lk)("div",p,[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),[[o.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),[[o.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"}},w=i(6262);const _=(0,w.A)(C,[["render",L]]);var E=_},9018:function(e,s,i){i.r(s),i.d(s,{default:function(){return M}});var t=i(641),o=i(33);const l={class:"biz-page"},a={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"},h={class:"plans-grid"},p={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"},y={key:0,class:"current-label"},L=["disabled"],f={key:1,class:"billing-section"},C={class:"billing-card"},w={class:"billing-row"},_={class:"billing-row"},E={key:0,class:"billing-row"},F={key:1,class:"billing-row"},S={class:"billing-actions"},X=["disabled"],U={key:2,class:"biz-error"};function W(e,s,i,W,x,z){const P=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",l,[(0,t.Lk)("div",a,[(0,t.Lk)("div",n,[s[5]||(s[5]=(0,t.Lk)("h1",null,"Manage Subscription",-1)),(0,t.bF)(P,{to:"/business/dashboard",class:"back-link"},{default:(0,t.k6)((()=>s[4]||(s[4]=[(0,t.eW)("← Back to Dashboard")]))),_:1})]),x.lounge?((0,t.uX)(),(0,t.CE)("div",r,[(0,t.Lk)("h2",null,(0,o.v_)(x.lounge.name),1),(0,t.Lk)("div",{class:(0,o.C4)(["plan-badge",x.lounge.tier])},(0,o.v_)("featured"===x.lounge.tier?"★ Featured":"basic"===x.lounge.tier?"Basic":"Free"),3),"free"!==x.lounge.tier||x.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"===x.lounge.tier&&x.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",h,[(0,t.Lk)("div",{class:(0,o.C4)(["plan-card",{active:"free"===z.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",p,["free"===z.currentTier?((0,t.uX)(),(0,t.CE)("span",k,"Current Plan")):((0,t.uX)(),(0,t.Wv)(P,{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,o.C4)(["plan-card",{active:"basic"===z.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"===z.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=>z.subscribe("basic")),disabled:x.subscribing},(0,o.v_)(x.subscribing?"Loading...":"Upgrade — $29/yr"),9,m))])],2),(0,t.Lk)("div",{class:(0,o.C4)(["plan-card featured-plan",{active:"featured"===z.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"===z.currentTier?((0,t.uX)(),(0,t.CE)("span",y,"Current Plan")):((0,t.uX)(),(0,t.CE)("button",{key:1,class:"plan-btn featured-btn",onClick:s[1]||(s[1]=e=>z.subscribe("featured")),disabled:x.subscribing},(0,o.v_)(x.subscribing?"Loading...":"Go Featured — $149/yr"),9,L))])],2)])]),x.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,o.v_)(x.subscription.tier),1)]),(0,t.Lk)("div",_,[s[12]||(s[12]=(0,t.Lk)("span",null,"Status:",-1)),(0,t.Lk)("strong",{class:(0,o.C4)(x.subscription.status)},(0,o.v_)(x.subscription.status),3)]),x.subscription.current_period_end?((0,t.uX)(),(0,t.CE)("div",E,[s[13]||(s[13]=(0,t.Lk)("span",null,"Next renewal:",-1)),(0,t.Lk)("strong",null,(0,o.v_)(new Date(x.subscription.current_period_end).toLocaleDateString("en-US",{month:"long",day:"numeric",year:"numeric"})),1)])):(0,t.Q3)("",!0),x.subscription.cancel_at_period_end?((0,t.uX)(),(0,t.CE)("div",F,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)=>z.openPortal&&z.openPortal(...e)),disabled:x.portalLoading},(0,o.v_)(x.portalLoading?"Loading...":"Update Payment Method"),9,X),x.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)=>z.cancelSub&&z.cancelSub(...e))},"Cancel Subscription"))])])])):(0,t.Q3)("",!0),x.error?((0,t.uX)(),(0,t.CE)("p",U,(0,o.v_)(x.error),1)):(0,t.Q3)("",!0)])])}i(4114);var x=i(7465),z={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(x.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(x.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){this.subscribing=!0,this.error=null;try{const s=await fetch(x.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(x.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(x.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")}},P=i(6262);const T=(0,P.A)(z,[["render",W]]);var M=T},5652:function(e,s,i){i.r(s),i.d(s,{default:function(){return S}});var t=i(641),o=i(3751),l=i(33);const a={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"},h=["value"],p={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"},y={class:"ticket-date"},L={class:"ticket-msg"},f={key:0,class:"ticket-response"};function C(e,s,i,C,w,_){const E=(0,t.g2)("router-link");return(0,t.uX)(),(0,t.CE)("div",a,[(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)(E,{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,o.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),[[o.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,h)))),128))],512),[[o.u1,w.loungeId]])]),(0,t.Lk)("div",p,[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),[[o.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",y,(0,l.v_)(new Date(e.created_at).toLocaleDateString()),1)]),(0,t.Lk)("p",L,(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")}},E=i(6262);const F=(0,E.A)(_,[["render",C]]);var S=F}}]);
//# sourceMappingURL=business-pages.9d5423ed.js.map