Spaces:
Running
Running
| class CustomFooter extends HTMLElement { | |
| connectedCallback() { | |
| this.attachShadow({ mode: 'open' }); | |
| this.shadowRoot.innerHTML = ` | |
| <style> | |
| :host { | |
| display: block; | |
| width: 100%; | |
| background-color: #1e293b; | |
| color: white; | |
| } | |
| .container { | |
| max-width: 1200px; | |
| margin: 0 auto; | |
| padding: 3rem 1.5rem; | |
| } | |
| .footer-content { | |
| display: flex; | |
| flex-direction: column; | |
| gap: 2rem; | |
| } | |
| .footer-top { | |
| display: grid; | |
| grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); | |
| gap: 2rem; | |
| } | |
| .footer-logo { | |
| font-size: 1.5rem; | |
| font-weight: 700; | |
| color: white; | |
| text-decoration: none; | |
| display: flex; | |
| align-items: center; | |
| gap: 0.5rem; | |
| margin-bottom: 1rem; | |
| } | |
| .footer-links { | |
| display: flex; | |
| flex-direction: column; | |
| gap: 0.75rem; | |
| } | |
| .footer-link { | |
| color: #cbd5e1; | |
| text-decoration: none; | |
| transition: color 0.2s; | |
| } | |
| .footer-link:hover { | |
| color: white; | |
| } | |
| .footer-bottom { | |
| border-top: 1px solid #334155; | |
| padding-top: 2rem; | |
| text-align: center; | |
| color: #94a3b8; | |
| font-size: 0.875rem; | |
| } | |
| @media (min-width: 768px) { | |
| .footer-content { | |
| gap: 4rem; | |
| } | |
| } | |
| </style> | |
| <footer> | |
| <div class="container"> | |
| <div class="footer-content"> | |
| <div class="footer-top"> | |
| <div> | |
| <a href="/" class="footer-logo"> | |
| <i data-feather="box"></i> | |
| PosterPuzzle | |
| </a> | |
| <p class="text-slate-300">Create stunning large posters from your favorite images.</p> | |
| </div> | |
| <div> | |
| <h4 class="font-medium text-lg mb-3">Quick Links</h4> | |
| <div class="footer-links"> | |
| <a href="/" class="footer-link">Home</a> | |
| <a href="#" class="footer-link">How it works</a> | |
| <a href="#" class="footer-link">Tutorial</a> | |
| </div> | |
| </div> | |
| <div> | |
| <h4 class="font-medium text-lg mb-3">Resources</h4> | |
| <div class="footer-links"> | |
| <a href="#" class="footer-link">Help Center</a> | |
| <a href="#" class="footer-link">Privacy Policy</a> | |
| <a href="#" class="footer-link">Terms of Service</a> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="footer-bottom"> | |
| © ${new Date().getFullYear()} PosterPuzzle Maker. All rights reserved. | |
| </div> | |
| </div> | |
| </div> | |
| </footer> | |
| `; | |
| } | |
| } | |
| customElements.define('custom-footer', CustomFooter); |