const BR_EXTRA={
  powai:{photo:SP_PHOTOS.storefront,alt:'Smile Plus Dental Clinic storefront and signage',
    caption:'Clinic signage — Powai Vihar branch',
    dir:'https://maps.app.goo.gl/GBKuYguBEvaaUgJ88',
    landmark:'Next to Optic Vision, near Gopal Sharma Memorial School.'},
  chandivali:{photo:SP_PHOTOS.chandivaliExterior,alt:'Smile Plus Dental Clinic storefront and signage — Chandivali branch',
    caption:'Clinic signage — Chandivali branch',
    dir:'https://maps.app.goo.gl/FmdjEoDufoVMqofb8',
    landmark:'Lake Primrose, Phase 4, off Lake Homes Private Road.'}
};
function ContactPage(){
  return <React.Fragment>
    <SPHead active="Contact"/>
    <main>
    <PageHero eyebrow="Locations" title="Two clinics, both in the Powai area."
      lead={SP_CLINIC.hoursLine+'. One number reaches both branches — call or message and we will hold a slot.'}
      photo={SP_PHOTOS.reception} alt="Reception at Smile Plus Dental Clinic">
      <div className="sp-cta-row">
        <CallBtns/>
      </div>
    </PageHero>

    <section className="sp-sec" style={{background:'var(--surface-page)'}}>
      <div className="sp-wrap sp-stack" style={{gap:'clamp(32px,4vw,56px)'}}>
        {SP_BRANCHES.map((b,i)=>{const x=BR_EXTRA[b.id];return <Reveal key={b.id} delay={i*60}>
          <Card padding={0} style={{overflow:'hidden'}}>
            <div style={{display:'grid',gridTemplateColumns:'repeat(auto-fit,minmax(290px,1fr))'}}>
              <div style={{minHeight:250,position:'relative',background:'var(--ink-150)'}}>
                {x.photo?<img src={x.photo} alt={x.alt} style={{position:'absolute',inset:0,width:'100%',height:'100%',objectFit:'contain'}}/>
                  :<div className="sp-slot" style={{position:'absolute',inset:0,border:0,borderRadius:0}}>
                    <Icon name="camera" size={20} color="var(--teal-600)"/>
                    <span className="sp-slot__t">{x.slot}</span><span className="sp-slot__d">{x.slotNote}</span></div>}
              </div>
              <div className="sp-stack" style={{gap:14,padding:'clamp(24px,3vw,34px)'}}>
                <div className="sp-row" style={{justifyContent:'space-between',gap:12}}>
                  <h2 className="sp-h3">{b.name} branch</h2>
                  <RatingPill branch={b}/>
                </div>
                <span className="sp-body">{b.address}</span>
                <span className="sp-data">{x.landmark}</span>
                <span className="sp-hr-gold"/>
                {SP_CLINIC.hours.map(([d,t],n)=><div key={n} style={{display:'flex',justifyContent:'space-between',gap:14,fontSize:14.5,color:'var(--text-body)'}}>
                  <span>{d}</span><span style={{font:'var(--type-data)',letterSpacing:'var(--ls-mono)',color:'var(--text-heading)'}}>{t}</span></div>)}
                <div className="sp-row" style={{gap:10,marginTop:6}}>
                  <a className="sp-plain" href={'tel:'+b.tel}><Button size="sm" variant="accent" icon="phone">Call {b.phone}</Button></a>
                  <WaButton size="sm" wa={b.wa} waText={b.waText} msg={'Hello Smile Plus, I would like an appointment at the '+b.name+' branch.'}/>
                  <a className="sp-plain" href={x.dir} target="_blank" rel="noopener"><Button size="sm" variant="secondary" icon="map-pin">Directions</Button></a>
                </div>
              </div>
            </div>
            <iframe title={b.name+' branch map'} src={b.map} loading="lazy" style={{width:'100%',minHeight:250,border:0,display:'block',background:'var(--ink-150)',borderTop:'1px solid var(--border-hairline)'}}></iframe>
          </Card></Reveal>;})}
      </div>
    </section>

    <section className="sp-sec" style={{background:'var(--surface-page)'}}>
      <div className="sp-wrap sp-grid-2" style={{alignItems:'center'}}>
        <Reveal className="sp-stack" style={{gap:18,alignItems:'flex-start'}}>
          <span className="sp-eyebrow" style={{color:'var(--text-gold)'}}>Before you come in</span>
          <h2 className="sp-h2">What to bring, and what to expect.</h2>
          <div className="sp-stack" style={{gap:12}}>
            {[['file-text','Any earlier X-rays or reports','If another clinic has treated the tooth, bring what they gave you.'],
              ['message-circle','Your questions','The consultation includes a one-to-one discussion of the plan and the cost.'],
              ['clock','A little time','Morning and evening sessions run six days a week; Sunday is by appointment.']].map(([ic,t,d])=>
              <span key={t} className="sp-row" style={{gap:13,alignItems:'flex-start',flexWrap:'nowrap'}}>
                <span style={{width:38,height:38,flex:'none',borderRadius:'var(--radius-md)',background:'var(--teal-100)',display:'flex',alignItems:'center',justifyContent:'center'}}>
                  <Icon name={ic} size={19} color="var(--teal-700)"/></span>
                <span className="sp-stack" style={{gap:2}}>
                  <span style={{fontFamily:'var(--font-display)',fontWeight:700,fontSize:16,color:'var(--text-heading)'}}>{t}</span>
                  <span className="sp-body" style={{fontSize:14.5}}>{d}</span></span>
              </span>)}
          </div>
        </Reveal>
        <Reveal delay={70}><Para src={SP_PHOTOS.posters} alt="Patient education posters in the Smile Plus waiting area" ratio="4 / 3.4" gold radius="var(--radius-xl)"/></Reveal>
      </div>
    </section>

    <CTABand title="Call the branch that suits you."/>
    </main>
    <SPFooter/>
  </React.Fragment>;
}
ReactDOM.createRoot(document.getElementById('root')).render(<ContactPage/>);
