Spaces:
Running
Running
Reframe Right to Energy around fair bills and fair returns
Browse filesBroaden the intro mission to electricity, gas and rooftop solar returns. Put supplier prices, network costs, policy charges and taxes under evidence-based scrutiny, and label the available action as electricity analysis. Preserve the Bhor Bohr film and existing playback and workspace behaviour.
Files changed (3)
- EnergyIntro.jsx+13-5
- README.md+9-3
- intro.css+9-5
12234559 unmodified lines65666768686970717273747475767778798081828384851 unmodified line878889829091929394959689979899import React, {useEffect, useId, useRef, useState} from 'react';import {ArrowDownRight, ArrowRight, ChevronDown, ChevronUp, Pause, Play, RotateCcw, Volume2, VolumeX, Zap} from 'lucide-react';import {ArrowDownRight, ArrowRight, ChevronDown, ChevronUp, Flame, Pause, Play, RotateCcw, Sun, Volume2, VolumeX, Zap} from 'lucide-react';import './intro.css';
function EnergyField() {59 unmodified lines const start=()=>{collapse(false);onStart?.();}; const replay=()=>{if(video.current)video.current.currentTime=0;setEnded(false);setProgress(0);playFilm();};
if(!expanded)return <section ref={root} className="energy-intro-collapsed" aria-label="Right to Energy introduction"><span><Zap size={17}/><strong>Right to Energy.</strong><small>Clarity for households & NGOs.</small></span><button ref={showControl} type="button" onClick={expand}>Show intro <ChevronDown size={15}/></button></section>; if(!expanded)return <section ref={root} className="energy-intro-collapsed" aria-label="Right to Energy introduction"><span><Zap size={17}/><strong>Right to Energy.</strong><small>Fair bills. Fair returns.</small></span><button ref={showControl} type="button" onClick={expand}>Show intro <ChevronDown size={15}/></button></section>;
return <section ref={root} className="energy-intro" data-motion={moving?'running':'paused'} aria-labelledby="energy-intro-title"> <EnergyField/> <div className="energy-intro-top"><span className="energy-edition"><i/>XENOWATTZ PRESENTS <span>/</span> RIGHT TO ENERGY</span><button ref={hideControl} type="button" className="energy-hide" onClick={()=>collapse()} aria-label="Hide introduction">Hide intro <ChevronUp size={14}/></button></div> <div className="energy-intro-body"> <div className="energy-intro-copy"><p className="energy-audience">FOR HOUSEHOLDS. FOR NGOs. FOR YOU.</p><h2 id="energy-intro-title">Right to<br/><span>Energy.</span><svg viewBox="0 0 70 70" aria-hidden="true" focusable="false"><path d="M18 15h37v37M55 15L15 55"/></svg></h2><p className="energy-promise">Clarity for every household.<br/>Evidence for every NGO.</p><button className="energy-start" type="button" onClick={start}>Start an analysis <ArrowRight size={18}/></button><p className="energy-caption">Your data. A fresh forecast. A clearer decision.</p></div> <div className="energy-intro-copy"> <p className="energy-audience">FOR HOUSEHOLDS. NGOs. SMALL BUSINESSES.</p> <h2 id="energy-intro-title">Right to<br/><span>Energy.</span><svg viewBox="0 0 70 70" aria-hidden="true" focusable="false"><path d="M18 15h37v37M55 15L15 55"/></svg></h2> <p className="energy-promise">Fair bills. Fair returns.</p> <ul className="energy-focus" aria-label="Our mission"><li><Zap size={13} aria-hidden="true"/>Electricity</li><li><Flame size={13} aria-hidden="true"/>Gas</li><li><Sun size={13} aria-hidden="true"/>Solar returns</li></ul> <p className="energy-mission">What you pay. What your roof earns. Put supplier prices, network costs, policy charges and taxes under scrutiny.</p> <button className="energy-start" type="button" onClick={start}>Analyse electricity <ArrowRight size={18}/></button> <p className="energy-caption">Electricity tools live now. Your data. A fresh forecast.</p> </div> <div className="energy-film-column"> <div className="energy-film-label"><span><i/>MEET BHOR BOHR</span><span>THE INTRO <span className="energy-slash">/</span> 10 SEC</span></div> <div className={`energy-film${playing?' is-playing':''}`}>1 unmodified line <source src="/brand/right-to-energy-intro-mobile.mp4" type="video/mp4" media="(max-width: 640px)"/> <source src="/brand/right-to-energy-intro.mp4" type="video/mp4"/> </video> {!playing&&<button type="button" className="energy-film-play" onClick={toggleFilm} aria-label={ended?'Replay Bhor Bohr intro':'Play Bhor Bohr intro'}><span>{ended?<RotateCcw size={24}/>:<Play size={24} fill="currentColor"/>}</span><strong>{ended?'Once more?':'A little current.'}</strong><small>{ended?'Replay the intro':'A lot of character. Press play.'}</small></button>} {!playing&&<button type="button" className="energy-film-play" onClick={toggleFilm} aria-label={ended?'Replay Bhor Bohr intro':'Play Bhor Bohr intro'}><span>{ended?<RotateCcw size={24}/>:<Play size={24} fill="currentColor"/>}</span><strong>{ended?'Once more?':'Every bill deserves a question.'}</strong><small>{ended?'Replay the intro':'Press play. Then follow the numbers.'}</small></button>} <div className="energy-film-controls"><button type="button" onClick={toggleFilm} aria-label={playing?'Pause intro':'Play intro'}>{playing?<Pause size={16}/>:<Play size={16}/>}<span>{playing?'Pause':ended?'Replay':'Play'}</span></button><span className="energy-film-progress" aria-hidden="true"><i style={{transform:`scaleX(${progress})`}}/></span><button type="button" onClick={()=>setMuted(previous=>!previous)} aria-label={muted?'Turn intro sound on':'Mute intro sound'} aria-pressed={!muted}>{muted?<VolumeX size={17}/>:<Volume2 size={17}/>}</button><button type="button" onClick={replay} aria-label="Restart intro"><RotateCcw size={15}/></button></div> </div> <div className="energy-character-line"><span className="energy-quote-mark">“</span><p>Even Bhor Bohr has bills to pay.</p><span className="energy-character-credit">BHOR BOHR<br/><b>RESIDENT ENERGY REBEL</b></span></div> {mediaError&&<p className="energy-media-error" role="status">{mediaError}</p>} </div> </div> <div className="energy-intro-bottom"><span><ArrowDownRight size={16}/> FROM THE GRID TO YOUR EVERYDAY.</span><button type="button" onClick={toggleMotion} aria-pressed={motionPaused}>{motionPaused?<Play size={12}/>:<Pause size={12}/>} {motionPaused?'Resume motion':'Pause motion'}</button></div> <div className="energy-intro-bottom"><span><ArrowDownRight size={16}/> AFFORDABILITY. ACCOUNTABILITY. BALANCE.</span><button type="button" onClick={toggleMotion} aria-pressed={motionPaused}>{motionPaused?<Play size={12}/>:<Pause size={12}/>} {motionPaused?'Resume motion':'Pause motion'}</button></div> </section>;}17 unmodified lines181920212221222324252627282930313233342 unmodified lines373839344041424317 unmodified lines
## Right to Energy · animated introduction
The live workspace opens with a **Right to Energy** introduction for householdsand NGOs: a responsive title panel, animated SVG electrical paths and atomicThe live workspace opens with a **Right to Energy** introduction for households,NGOs and small businesses: a responsive title panel, animated SVG electrical paths and atomicorbits, and the user-supplied ten-second Bhor Bohr film. This is an audience andproduct theme, not a claim of nonprofit registration or external endorsement.
The message is **Fair bills. Fair returns.** Its wider mission covers electricity,gas and rooftop solar returns, with supplier prices, network costs, policy chargesand taxes open to evidence-based scrutiny. The current calculation tools coverelectricity; the intro does not present gas analysis or solar payback calculationsas available features, or assert a universal solar payback period.
The film preserves the original 16:9 composition and audio, with optimized720p and mobile 360p versions. It starts muted and plays only when requested;the poster loads before the video. Play, pause, replay and sound controls are2 unmodified linesvideo pauses automatically. The sidebar uses its existing static characterposter to avoid a second simultaneous animation.
**Start an analysis** collapses the introduction and moves focus to the**Analyse electricity** collapses the introduction and moves focus to theworkspace. Hiding or reopening the intro does not clear inputs or results.The original source is unchanged; `assets/right-to-energy-media.json` insidethe verified resource bundle records source/output hashes and encoding steps.13 unmodified lines14151617171819202122232442 unmodified lines6768696667686970717273747513 unmodified lines.energy-intro h2{position:relative;width:fit-content;font-family:'Manrope',system-ui,sans-serif;font-weight:800;font-size:clamp(42px,4.7vw,74px);line-height:.99;letter-spacing:-3.5px;margin:0 0 22px;color:#f1f4e7}.energy-intro h2>span{color:#cef798}.energy-intro h2>svg{position:absolute;width:48px;height:48px;top:9px;right:-65px;fill:none;stroke:#b6d495;stroke-width:1.1}.energy-promise{font-size:14px;line-height:1.65;letter-spacing:.1px;color:#c4d4bd;margin:0 0 24px}.energy-promise{font-size:23px;font-weight:600;line-height:1.3;letter-spacing:-.5px;color:#dce8d3;margin:0 0 16px}.energy-focus{display:flex;align-items:center;flex-wrap:wrap;gap:8px 15px;list-style:none;margin:0 0 13px;padding:0;color:#c9e3af;font-size:10px;font-weight:500}.energy-focus li{display:inline-flex;align-items:center;gap:5px;white-space:nowrap}.energy-focus svg{color:#b9db90;flex-shrink:0}.energy-mission{max-width:38ch;font-size:12px;line-height:1.65;color:#b5c9ab;margin:0 0 21px}.energy-start{display:inline-flex;align-items:center;justify-content:space-between;gap:30px;min-height:46px;padding:13px 17px;border:1px solid #d1f49e;border-radius:7px;font-size:11px;font-weight:700;color:#172c23;background:#d0f49b;box-shadow:0 3px 12px #04130b22}.energy-start:hover{background:#e1ffb7;border-color:#e1ffb7}.energy-start svg{transition:transform .2s}42 unmodified lines.page-heading[tabindex="-1"]:focus{outline:0}@keyframes energy-flow{to{stroke-dashoffset:-1292}}@keyframes energy-rotation{to{transform:rotate(360deg)}}@media(min-width:1500px){.energy-intro-body{padding:30px 38px 22px;gap:44px}.energy-intro-top,.energy-intro-bottom{padding-left:38px;padding-right:38px}.energy-promise{font-size:16px}.energy-intro h2{font-size:78px}.energy-film-play>span{width:60px;height:60px}.energy-film-play{padding-bottom:28px}}@media(max-width:1100px){.energy-intro-body{gap:22px;padding:24px}.energy-intro-top,.energy-intro-bottom{padding-left:24px;padding-right:24px}.energy-intro h2{font-size:50px;letter-spacing:-2.6px}.energy-intro h2>svg{width:36px;right:-43px}.energy-promise{font-size:12px}.energy-audience{font-size:7px;letter-spacing:1.1px}.energy-character-credit{display:none}.energy-film-label{font-size:7px;letter-spacing:.9px}.energy-film-label>span:last-child{font-size:6px}.energy-film-play{padding-bottom:13px}.energy-film-play>span{width:40px;height:40px;margin-bottom:9px}.energy-film-play strong{font-size:12px}.energy-film-play small{font-size:8px}.energy-edition{font-size:7px;letter-spacing:1px}}@media(max-width:900px) and (min-width:751px){.energy-intro-body{grid-template-columns:1fr;gap:28px}.energy-intro-copy{padding-right:0}.energy-intro h2{font-size:68px}.energy-intro h2 br{display:none}.energy-intro h2>span:before{content:' '}.energy-intro h2>svg{display:none}.energy-promise br{display:none}.energy-promise{max-width:370px;font-size:13px}.energy-intro-copy{position:relative}.energy-film-column{max-width:560px;width:100%}.energy-character-credit{display:block}.energy-film-play>span{width:54px;height:54px}.energy-film-play{padding-bottom:25px}}@media(max-width:750px){.energy-intro{border-radius:15px;margin-bottom:25px}.energy-intro-body{grid-template-columns:1fr;gap:28px;padding:24px 23px 20px}.energy-intro-top{padding:17px 22px 0}.energy-edition{font-size:6px;letter-spacing:.8px;gap:6px}.energy-edition>span{margin:0}.energy-hide{font-size:8px;gap:4px}.energy-audience{font-size:7px;letter-spacing:1.2px;margin-bottom:13px}.energy-intro h2{font-size:clamp(53px,11vw,74px);letter-spacing:-3px;margin-bottom:20px}.energy-intro h2>svg{width:43px;height:43px;right:-59px;top:9px}.energy-promise{font-size:14px;margin-bottom:22px}.energy-start{min-height:46px;font-size:11px;gap:40px}.energy-caption{font-size:9px}.energy-film-column{padding:0}.energy-film-label{font-size:7px;letter-spacing:1.2px;margin-bottom:10px}.energy-film-label>span:last-child{font-size:6px}.energy-film-play>span{width:48px;height:48px;margin-bottom:10px}.energy-film-play strong{font-size:14px}.energy-film-play small{font-size:9px}.energy-film-play{padding-bottom:18px}.energy-character-line{padding-top:15px}.energy-character-line p{font-size:10px}.energy-character-credit{display:block;font-size:6px;letter-spacing:.7px;padding-left:9px}.energy-character-credit b{font-size:5px}.energy-intro-bottom{padding:14px 22px;margin:0;gap:12px}.energy-intro-bottom>span{font-size:6px;letter-spacing:.9px;gap:5px}.energy-intro-bottom>span svg{width:13px}.energy-intro-bottom>button{font-size:8px}.energy-intro-collapsed{padding:12px}.energy-intro-collapsed small{display:none}}@media(min-width:1500px){.energy-intro-body{padding:30px 38px 22px;gap:44px}.energy-intro-top,.energy-intro-bottom{padding-left:38px;padding-right:38px}.energy-promise{font-size:26px}.energy-intro h2{font-size:78px}.energy-film-play>span{width:60px;height:60px}.energy-film-play{padding-bottom:28px}}@media(max-width:1100px){.energy-intro-body{gap:22px;padding:24px}.energy-intro-top,.energy-intro-bottom{padding-left:24px;padding-right:24px}.energy-intro h2{font-size:50px;letter-spacing:-2.6px}.energy-intro h2>svg{width:36px;right:-43px}.energy-promise{font-size:21px}.energy-audience{font-size:7px;letter-spacing:1.1px}.energy-character-credit{display:none}.energy-film-label{font-size:7px;letter-spacing:.9px}.energy-film-label>span:last-child{font-size:6px}.energy-film-play{padding-bottom:13px}.energy-film-play>span{width:40px;height:40px;margin-bottom:9px}.energy-film-play strong{font-size:12px}.energy-film-play small{font-size:8px}.energy-edition{font-size:7px;letter-spacing:1px}}@media(max-width:900px) and (min-width:751px){.energy-intro-body{grid-template-columns:1fr;gap:28px}.energy-intro-copy{padding-right:0}.energy-intro h2{font-size:68px}.energy-intro h2 br{display:none}.energy-intro h2>span:before{content:' '}.energy-intro h2>svg{display:none}.energy-promise br{display:none}.energy-promise{max-width:370px;font-size:23px}.energy-intro-copy{position:relative}.energy-film-column{max-width:560px;width:100%}.energy-character-credit{display:block}.energy-film-play>span{width:54px;height:54px}.energy-film-play{padding-bottom:25px}}@media(max-width:750px){.energy-intro{border-radius:15px;margin-bottom:25px}.energy-intro-body{grid-template-columns:1fr;gap:28px;padding:24px 23px 20px}.energy-intro-top{padding:17px 22px 0}.energy-edition{font-size:6px;letter-spacing:.8px;gap:6px}.energy-edition>span{margin:0}.energy-hide{font-size:8px;gap:4px}.energy-audience{font-size:7px;letter-spacing:1.2px;margin-bottom:13px}.energy-intro h2{font-size:clamp(53px,11vw,74px);letter-spacing:-3px;margin-bottom:20px}.energy-intro h2>svg{width:43px;height:43px;right:-59px;top:9px}.energy-promise{font-size:23px;margin-bottom:16px}.energy-start{min-height:46px;font-size:11px;gap:40px}.energy-caption{font-size:9px}.energy-film-column{padding:0}.energy-film-label{font-size:7px;letter-spacing:1.2px;margin-bottom:10px}.energy-film-label>span:last-child{font-size:6px}.energy-film-play>span{width:48px;height:48px;margin-bottom:10px}.energy-film-play strong{font-size:14px}.energy-film-play small{font-size:9px}.energy-film-play{padding-bottom:18px}.energy-character-line{padding-top:15px}.energy-character-line p{font-size:10px}.energy-character-credit{display:block;font-size:6px;letter-spacing:.7px;padding-left:9px}.energy-character-credit b{font-size:5px}.energy-intro-bottom{padding:14px 22px;margin:0;gap:12px}.energy-intro-bottom>span{font-size:6px;letter-spacing:.9px;gap:5px}.energy-intro-bottom>span svg{width:13px}.energy-intro-bottom>button{font-size:8px}.energy-intro-collapsed{padding:12px}.energy-intro-collapsed small{display:none}}@media(max-width:380px){.energy-edition>span{display:none}.energy-edition{font-size:5.5px;letter-spacing:.5px}.energy-intro-body{padding-left:19px;padding-right:19px}.energy-intro h2>svg{display:none}.energy-character-credit{display:none}.energy-film-play>span{width:39px;height:39px;margin-bottom:7px}.energy-film-play strong{font-size:12px}.energy-film-play small{font-size:8px}.energy-intro-bottom>span{letter-spacing:.5px}}@media(prefers-reduced-motion:reduce){.energy-intro *,.energy-intro-collapsed *{transition:none!important}}EnergyIntro.jsx+13-5
README.md+9-3
intro.css+9-5