An agency footer in pure CSS and vanilla JavaScript that ends the page with an oversized "Let's talk" email link, a copy email button and a list of studio cities with their live local time. Use this contact footer template for creative agencies, design studios and consultancies that want a clear call to action at the bottom of every page.
How it works
The root .agf-root holds a thin .agf-strip (the end of a case study page) and the footer.agf-footer. Inside, .agf-top places the call to action (.agf-cta) next to .agf-offices; from 1000px they sit side by side, on phones they stack. a.agf-talk is a real mailto: link set in Syne at --agf-talk-size. Below it, .agf-copy copies the address stored in data-agf-email.
script.js tries navigator.clipboard.writeText() first and falls back to a hidden textarea with document.execCommand('copy'). On success the button label changes to "Copied" for 2.5 seconds; if the browser blocks copying, the address text is selected and the .agf-status message tells the visitor to press Ctrl+C.
Each .agf-office has data-agf-tz (an IANA time zone) plus data-agf-open and data-agf-close hours. The script formats the time in that zone with Intl.DateTimeFormat, writes it into time.agf-time, and adds .is-open on weekdays inside office hours, otherwise it shows when the studio opens again. It refreshes every 15 seconds. .agf-grid holds the logo, description, social icons, two link columns and a careers note; .agf-legal shows the copyright year computed in JavaScript.
Customization
--agf-accenton.agf-root: the lime color of the arrow, copy button, open dot and focus rings.--agf-bg,--agf-textand--agf-muted: footer background, main text and secondary text. Change thebodybackground instyle.cssto match--agf-bg.--agf-talk-size: the size of the "Let's talk" link; lower the clamp maximum for a quieter call to action.data-agf-emailon.agf-copy: the address that is copied. Update themailto:link and.agf-mail-texttoo.data-agf-tz,data-agf-openanddata-agf-closeon each.agf-office: time zone and opening hours of a studio. Add or removeli.agf-officeitems freely.--agf-displayand--agf-body: the Syne and Inter font stacks loaded from Google Fonts.
Use cases
- Creative agencies: a large call to action invites new briefs on every page
- Design studios with several offices: visitors see whether a studio is open right now
- Consultancies: the copy button helps people who do not use a desktop mail app
- Portfolio sites: a careers note and social links close the page
Accessibility
Link groups are nav elements with aria-label, every column title is a heading and studio addresses use address. The copy result is announced by .agf-status (role="status", aria-live="polite"). Social icons are generic SVGs with the network name in visually hidden .agf-sr text. All controls are at least 40px tall, show a lime :focus-visible outline, and transitions switch off with prefers-reduced-motion: reduce.
Usage notes
The Clipboard API needs a secure context (HTTPS); the fallback covers sandboxed previews. Times are computed from the visitor's clock, so no dates go stale.