---
// Base layout: head, skip link, header, footer, theme handling.
// Pages wrap their content in <Base title tag>...</Base>.
import BaseHead from '../components/BaseHead.astro';
import Header from '../components/Header.astro';
import Footer from '../components/Footer.astro';
import '../styles/global.css';

interface Props {
  title: string;
  description?: string;
  /** rel=canonical path, e.g. "/projects/fft-ntt/". Defaults to the current path. */
  canonical?: string;
}

const { title, description = '', canonical } = Astro.props;
---

<!doctype html>
<html lang="en" data-theme="dark">
  <head>
    <BaseHead title={title} description={description} canonical={canonical} />
  </head>
  <body>
    <a class="skip-link" href="#main">Skip to content</a>
    <Header />
    <main class="wrap" id="main">
      <slot />
    </main>
    <Footer />
  </body>
</html>
