# Security headers — docs/09 §4.
#
# CSP is SPLIT, deliberately (spike S1, 2026-07-27):
#   * script-src / style-src live in the per-page <meta http-equiv> that Astro
#     generates (astro.config.ts `security.csp`), because only the build knows
#     the hashes of the island-hydration snippets Astro itself emits. A static
#     file cannot.
#   * frame-ancestors lives HERE, because meta-tag CSP ignores it by spec.
# A header CSP and a meta CSP are enforced as SEPARATE policies and a resource
# must satisfy BOTH. So this file must never also declare default-src,
# script-src or style-src — the intersection would drop Astro's hashes and
# break every island.
#
# The pre-launch `X-Robots-Tag: noindex` was REMOVED on 2026-07-28. It existed
# only while the dataset was empty, where an indexed blank site can linger as
# "Crawled — currently not indexed". With real entries, legal pages and a
# sitemap live, that objection no longer applies and indexing is wanted.
# robots.txt (docs/16 §7) has always been the permanent control.

/*
  Content-Security-Policy: frame-ancestors 'none'
  X-Content-Type-Options: nosniff
  X-Frame-Options: DENY
  Referrer-Policy: strict-origin-when-cross-origin
  Permissions-Policy: camera=(), microphone=(), geolocation=(), payment=(), usb=()
  Cross-Origin-Opener-Policy: same-origin
  Cross-Origin-Resource-Policy: same-origin
  Cache-Control: public, max-age=0, must-revalidate

# Content-hashed by Vite — this covers JS, CSS *and* the self-hosted fonts,
# which Astro emits into /_astro/ rather than a /fonts/ directory. An earlier
# spec had a separate /fonts/* rule; it matched nothing (found in M1).
/_astro/*
  Cache-Control: public, max-age=31536000, immutable

/api/apps.json
  Access-Control-Allow-Origin: *
  Cache-Control: public, max-age=300

/search-index.json
  Cache-Control: public, max-age=300
