/*
 * Palette from the "Palettes de couleurs" section of docs/specs.md. The values repeat the
 * tokens of src/constants/theme.ts (this static site cannot import them): keep both in sync.
 */
:root {
  --background: #f7f8f6;
  --card: #ffffff;
  --tile: #e0eee8;
  --text: #000000;
  --text-secondary: #666666;
  --banner: #004128;
  --text-on-banner: #ffffff;
  --accent: #004128;
  --alert-background: #fff4d2;
  --alert-text: #613d00;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #14181a;
    --card: #1c2224;
    --tile: #262e30;
    --text: #e8eeec;
    --text-secondary: #9aa8a5;
    --banner: #1d4a3c;
    --text-on-banner: #e8eeec;
    --accent: #8ed3b4;
    --alert-background: #2b2619;
    --alert-text: #ddbb6e;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family:
    -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
}

header {
  background: var(--banner);
  color: var(--text-on-banner);
  padding: 16px;
}

header a {
  color: inherit;
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
}

main {
  max-width: 640px;
  margin: 0 auto;
  padding: 32px 16px 48px;
}

h1 {
  color: var(--accent);
  font-size: 1.75rem;
  line-height: 1.25;
  margin: 0 0 16px;
}

p {
  margin: 0 0 16px;
}

a {
  color: var(--accent);
}

.card {
  background: var(--card);
  border-radius: 16px;
  padding: 24px;
}

.notice {
  background: var(--alert-background);
  color: var(--alert-text);
  border-radius: 12px;
  padding: 12px 16px;
}

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0 0;
}

.store {
  background: var(--tile);
  border-radius: 12px;
  color: var(--text-secondary);
  min-height: 48px;
  padding: 12px 16px;
}

footer {
  color: var(--text-secondary);
  font-size: 0.875rem;
  padding: 0 16px 32px;
  text-align: center;
}

footer a {
  color: inherit;
}

/* Bilingual pages: French by default, English when the browser asks for it (see page.js). */
html[lang='en'] [lang='fr'],
html[lang='fr'] [lang='en'] {
  display: none;
}

/* Expired or already used link (see page.js): swap the normal content for the error message. */
[data-when='invalid'],
html[data-link='invalid'] [data-when='valid'] {
  display: none;
}

html[data-link='invalid'] [data-when='invalid'] {
  display: block;
}
