/* THE TOP MENU, one file for every page.

   Patrick, 21 Nov 2026, on the old bar: "this feels like it needs to be updated and add a 3 line drop down in either
   left or right corner EDDM should have its own thing too. and everythign should be in the drop down plus about just
   lives there." He was shown three drawings and picked "option C with this from option A", and when asked which part of
   A, "Links in the bar". So:
     - the bar keeps its links and EDDM gets its own (Printing, Direct Mail, EDDM, Mass Email & Text, Union & Political);
     - About and Get a quote left the bar and live in the menu;
     - a Menu button (three lines) sits in the right corner of the window and opens one wide panel with every page in
       four groups;
     - on the home page the language box moved into that panel, and the dark strip that held it is gone.

   Each page keeps its own bar in its own HTML (logo, links, phone, button) plus one line for the Menu button. The panel
   is built by /site-menu.js, so its list of pages lives in one place. This file is loaded after the page's own styles
   and overrides the old bar rules that are still in each page (.mobile-toggle and .nav.open there are no longer used). */

/* THE BAR'S OWN LOOK, for the four pages with older, leaner styles of their own (Order, Order forms, Privacy,
   Thank-you). Their bar is marked class="header header-std" and gets here what the other pages carry in their own
   styles, so the bar is the same on every page. (These rules sit above the shared ones below on purpose, so the
   shared narrow-screen rules still win.) */
.header.header-std { position: sticky; top: 0; z-index: 100; background: #fff; border-bottom: 1px solid #e2e8f0; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05); }
.header-std > .header-inner { max-width: 1200px; margin: 0 auto; padding: 0.85rem 1.5rem; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.header-std .logo { display: flex; align-items: center; text-decoration: none; }
.header-std .logo .logo-img { height: 48px; width: auto; display: block; }
.header-std .nav { display: flex; align-items: center; margin: 0; }
.header-std .nav a { font-weight: 500; font-size: 0.9rem; color: #2d3748; text-decoration: none; white-space: nowrap; transition: color 0.2s; }
.header-std .nav a:hover, .header-std .nav a.current { color: #c53030; }
.header-std .header-cta { display: flex; align-items: center; gap: 1rem; margin: 0; }
.header-std .phone-link { display: flex; align-items: center; gap: 0.4rem; margin: 0; font-weight: 600; font-size: 0.95rem; color: #1a365d; text-decoration: none; white-space: nowrap; }
.header-std .phone-link:hover { color: #c53030; }
@media (max-width: 720px) {
  .header-std .phone-link span { display: none; }
  .header-std .logo .logo-img { height: 40px; }
}
@media (max-width: 400px) {
  .header-std > .header-inner { gap: 0.5rem; padding-left: 1rem; }
}

/* The bar is three columns: a spacer, the 1200px page column, and the corner that holds the Menu button. On a wide
   screen the two outer columns are equal, so the page column stays centred; on a narrower one the spacer gives way
   first, then the page column. */
.header { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1200px) minmax(max-content, 1fr); align-items: center; }
.header > .header-inner { grid-column: 2; min-width: 0; width: 100%; }

.menu-btn { grid-column: 3; justify-self: end; margin: 0 1.25rem 0 0.25rem; display: inline-flex; align-items: center; gap: 0.6rem; border: 1.5px solid #cbd5e0; border-radius: 9px; padding: 0.6rem 0.85rem; background: #fff; color: #1a365d; font: inherit; font-weight: 700; font-size: 0.92rem; line-height: 1.2; cursor: pointer; transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease; }
.menu-btn i { display: block; width: 20px; height: 14px; background: linear-gradient(currentColor, currentColor) top / 100% 2px no-repeat, linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat, linear-gradient(currentColor, currentColor) bottom / 100% 2px no-repeat; }
.menu-btn b { font-weight: 700; }
.menu-btn:hover { border-color: #1a365d; }
.menu-btn[aria-expanded="true"] { background: #1a365d; border-color: #1a365d; color: #fff; }

/* The links in the bar. Below 1240px they tighten up; below 1060px they fold away and the Menu button carries them. */
.header .nav { gap: 1.4rem; }
.header .nav a[href="/eddm.html"] { font-weight: 700; color: #1a365d; }
.header .nav a[href="/eddm.html"]:hover, .header .nav a[href="/eddm.html"].current { color: #c53030; }
@media (max-width: 1240px) {
  .header > .header-inner { gap: 1rem; }
  .header .nav { gap: 0.95rem; }
  .header .nav a { font-size: 0.87rem; }
}
@media (max-width: 1060px) {
  .header .nav { display: none; }
  .header .header-cta { margin-left: auto; }
}
/* Menu labels run longer in the home page's other languages, so there the links fold away sooner. */
@media (max-width: 1280px) {
  html:not(:lang(en)) .header .nav { display: none; }
  html:not(:lang(en)) .header .header-cta { margin-left: auto; }
}
@media (max-width: 720px) {
  .header > .header-inner { padding-right: 0.6rem; }
  .menu-btn { margin: 0 0.9rem 0 0; padding: 0.62rem 0.7rem; }
  .menu-btn b { display: none; }
}

/* THE PANEL: under the whole bar, every page in four groups, then the two buttons, the phone number and (home page
   only) the language box. It is always in the page and simply hidden until the Menu button is pressed. */
.site-menu { position: absolute; left: 0; right: 0; top: 100%; z-index: 1; background: #fff; border-top: 1px solid #e2e8f0; box-shadow: 0 24px 40px -16px rgba(15, 39, 68, 0.4); overflow-y: auto; overscroll-behavior: contain;
  visibility: hidden; opacity: 0; transform: translateY(-8px); transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s; }
.site-menu.open { visibility: visible; opacity: 1; transform: none; transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s; }
.sm-inner { max-width: 1200px; margin: 0 auto; padding: 1.6rem 1.5rem 1.3rem; text-align: left; }
.sm-cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.5rem; }
.sm-cols > div { min-width: 0; }
.sm-grp { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: #718096; margin: 0 0 0.5rem; padding-left: 0.65rem; line-height: 1.6; }
.sm-row { display: block; overflow-wrap: anywhere; padding: 0.5rem 0.65rem; border: 1px solid transparent; border-radius: 8px; font-weight: 600; font-size: 0.97rem; color: #1a365d; line-height: 1.3; text-decoration: none; transition: background 0.15s ease; }
.sm-row small { display: block; font-weight: 400; font-size: 0.82rem; color: #718096; margin-top: 0.05rem; }
.sm-row:hover { background: #eef3fa; }
.sm-row.hot { background: #eef3fa; border-color: #d5e0f0; }
.sm-row.hot:hover { border-color: #1a365d; }
.sm-row[aria-current="page"] { color: #c53030; }
.sm-tag { display: inline-block; margin-left: 0.4rem; vertical-align: 0.1em; font-size: 0.66rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; background: #c53030; color: #fff; border-radius: 999px; padding: 0.12rem 0.5rem; white-space: nowrap; }
.sm-foot { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin-top: 1.2rem; padding-top: 1rem; border-top: 1px solid #e2e8f0; }
.sm-btn { display: inline-flex; align-items: center; justify-content: center; padding: 0.7rem 1.4rem; font-weight: 600; font-size: 0.95rem; line-height: 1.6; border-radius: 8px; white-space: nowrap; text-decoration: none; border: 2px solid transparent; transition: background 0.2s ease, color 0.2s ease; }
.sm-btn.red { background: #c53030; border-color: #c53030; color: #fff; }
.sm-btn.red:hover { background: #9b2c2c; border-color: #9b2c2c; }
.sm-btn.line { border-color: #1a365d; color: #1a365d; }
.sm-btn.line:hover { background: #1a365d; color: #fff; }
.sm-phone { display: inline-flex; align-items: center; gap: 0.4rem; font-weight: 600; font-size: 0.95rem; color: #1a365d; white-space: nowrap; text-decoration: none; }
.sm-phone svg { width: 18px; height: 18px; }
.sm-phone:hover { color: #c53030; }
.sm-lang { margin-left: auto; display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; color: #2d3748; }
.sm-lang svg { width: 17px; height: 17px; color: #718096; }
.sm-lang select { background: #fff; color: #2d3748; border: 1px solid #cbd5e0; border-radius: 6px; padding: 0.3rem 0.55rem; font: inherit; font-size: 0.9rem; cursor: pointer; }
.sm-lang select:hover { border-color: #1a365d; }
.sm-note { flex-basis: 100%; font-size: 0.82rem; line-height: 1.4; color: #718096; }

/* The page dims behind the open panel; a click or tap on the dimmed part closes it. */
.sm-scrim { position: fixed; inset: 0; z-index: 99; background: rgba(15, 39, 68, 0.5); visibility: hidden; opacity: 0; transition: opacity 0.18s ease, visibility 0s linear 0.18s; }
.sm-scrim.open { visibility: visible; opacity: 1; transition: opacity 0.18s ease, visibility 0s; }

@media (max-width: 900px) {
  .sm-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.25rem; }
}
@media (max-width: 720px) {
  .sm-inner { padding: 1rem 0.8rem 0.95rem; }
  .sm-cols { gap: 0.7rem 0.4rem; }
  .sm-grp { margin-bottom: 0.25rem; }
  .sm-row { padding: 0.42rem 0.65rem; font-size: 0.95rem; }
  .sm-row small { display: none; }
  .sm-tag { margin-left: 0; }
  .sm-foot { gap: 0.6rem; margin-top: 0.8rem; padding-top: 0.8rem; }
  .sm-btn { padding: 0.55rem 1rem; font-size: 0.92rem; }
  .sm-lang { margin-left: 0; flex-basis: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .site-menu, .site-menu.open, .sm-scrim, .sm-scrim.open, .menu-btn { transition: none; }
}
