# Engineering Suite B2B

A single index with 28 connected calculators: 13 thermodynamics modules (Çengel & Boles),
4 McCabe workspaces, and 11 Mott modules. Everything runs client-side.

## Domain

The site is served from the root of **https://mccabe-solutions.com**. Every canonical tag,
Open Graph URL, `sitemap.xml` entry and `robots.txt` line already points there.

If the domain ever changes, `set-domain.mjs` rewrites all of them in one command:

```bash
node set-domain.mjs https://new-domain.com contact@new-domain.com
```

The second argument is optional; without it the contact address defaults to
`contact@<domain>`.

> The old canonical tags pointed at `https://mccabe-solutions.com/fluidtech/...`, a path
> that now returns 404. Canonicals must always resolve to a live URL, otherwise Google is
> told the real version of the page does not exist.

## Publishing

1. Publish all contents, preserving the `cengel`, `mccabe` and `mott` folders.
2. `ads.txt`, `robots.txt` and `sitemap.xml` must stay at the **root of the domain**
   (`https://mccabe-solutions.com/ads.txt`). AdSense only reads `ads.txt` from the root.
3. `index.html` is the only navigation entry point.
4. `404.html` is served by GitHub Pages for unknown paths. It carries no ads, by policy.
5. An internet connection is required for Tailwind, Chart.js, MathJax, jsPDF, html2canvas
   and AdSense.

## Layout

```
index.html              Calculator index (entry point)
about.html              What the project is, how modules are validated
contact.html            Contact routes and response times
privacy-policy.html     Data, cookies, Google AdSense disclosures, opt-outs
terms.html              Terms of use, licence, liability
disclaimer.html         Engineering scope and verification requirements
404.html                Not-found page (noindex, no ads)
ads.txt                 Authorised sellers declaration
robots.txt              Crawler rules; allows Mediapartners-Google explicitly
sitemap.xml             All indexable URLs
set-domain.mjs          Replaces the placeholder domain site-wide
cengel/ mccabe/ mott/   The 28 calculator pages
```

## AdSense conventions used here

- The loader script sits in `<head>` on every indexable page, `async`, with
  `crossorigin="anonymous"`.
- **No ad unit may live inside a modal, overlay or interstitial**, and no feature may be
  gated behind a timed ad view. Both patterns violate Google's ad placement policies.
- Ad containers use `min-height`, never a fixed `height`, so a taller ad expands its box
  instead of covering the content next to it.
- Every page links to the privacy policy, terms, disclaimer and contact page from its footer.
- Error pages carry no advertising.

## Language

All page content — titles, meta tags, body copy, chart labels, validation messages and the
generated PDF reports — is authored in English directly in the source. The former runtime
translation layer (`english-localization.js`) has been removed: it rewrote Spanish text in
the browser word by word, which produced broken English and corrupted LaTeX equations.
Nothing on the page is translated at run time any more.

## Scope

The calculations support preliminary engineering and must be verified for contractual or
safety-critical design. See `disclaimer.html`.
