/*
  chemprocesseng.com site chrome, shared by every page:
  navigation bar (logo, site name, section links, search), footer, back-to-top button.
  Load it last in <head>, after the page's own styles, so it wins over older inline rules:
    <link rel="stylesheet" href="/assets/css/site.css">
  Colours and type follow website/DESIGN.md. Literal values are used so the file works on any page.
*/

.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* ---------- Navigation bar ---------- */
.nav{background:#fff;border-bottom:1px solid #e5e7eb;font-family:"Open Sans",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif}
.nav-in{max-width:1200px;margin:0 auto;padding:0 40px;min-height:72px;height:auto;display:flex;flex-wrap:wrap;align-items:center;gap:0 32px;box-sizing:border-box}
.brand{display:inline-flex;align-items:center;gap:14px;flex:none;margin-right:auto;color:#000;text-decoration:none;border-radius:10px}
.brand img{display:block;width:52px;height:52px;flex:none}
.brand-name{font:400 22px/1.15 "Newsreader",Georgia,"Times New Roman",serif;letter-spacing:0;color:#000;white-space:nowrap}
.brand:hover .brand-name{text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:4px}
.nav nav{display:block}
.nav ul{list-style:none;margin:0;padding:0;display:flex;gap:28px}
.nav ul a{display:block;color:#000;text-decoration:none;font-size:15px;line-height:1.65;letter-spacing:-0.01em;padding:23px 0 21px;border-bottom:2px solid transparent;white-space:nowrap}
.nav ul a[aria-current="page"]{border-bottom-color:#000}
.nav ul a:hover{border-bottom-color:#b1b5b9}

/* Search box in the bar */
.site-search{display:flex;align-items:center;width:220px;height:40px;margin:0;border:1px solid #b1b5b9;border-radius:20px;background:#fff;box-sizing:border-box}
.site-search:focus-within{border-color:#12647e;outline:2px solid #12647e;outline-offset:0}
.site-search input{flex:1;min-width:0;height:100%;margin:0;border:0;outline:0;background:transparent;padding:0 4px 0 16px;font:400 15px "Open Sans",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;letter-spacing:-0.01em;color:#000;-webkit-appearance:none;appearance:none}
.site-search input::placeholder{color:#5f646a;opacity:1}
.site-search input::-webkit-search-decoration{-webkit-appearance:none}
.site-search button{flex:none;width:40px;height:38px;margin:0;padding:0;border:0;border-radius:0 20px 20px 0;background:transparent;color:#000;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;transition:background 200ms cubic-bezier(0.4,0.14,0.3,1)}
.site-search button:hover{background:#a6d7f0}
.site-search button:focus-visible{outline:2px solid #12647e;outline-offset:-2px}
.search-link{display:none}

/* Two rows when the bar runs out of width: logo + name and search, then the links */
@media (max-width:1140px){
  .nav-in{padding-top:10px;row-gap:2px}
  .site-search{order:1}
  .nav nav{order:2;width:100%}
  .nav ul a{padding:10px 0 9px}
}
@media (max-width:700px){ .nav-in{padding-left:20px;padding-right:20px} }
/* Phones: the search box becomes an icon that opens the search page */
@media (max-width:640px){
  .nav-in{padding:10px 20px 0;column-gap:12px}
  .brand{gap:10px}
  .brand img{width:44px;height:44px}
  .brand-name{font-size:18px;white-space:normal;max-width:9.6em}
  .site-search{display:none}
  .search-link{display:inline-flex;order:1;align-items:center;justify-content:center;width:44px;height:44px;border:1px solid #b1b5b9;border-radius:9999px;color:#000;flex:none}
  .search-link:hover{background:#a6d7f0}
  .nav ul{justify-content:space-between;gap:8px}
  .nav ul a{font-size:14px}
}

/* ---------- Footer ---------- */
.foot{background:#3a2206;color:#fff;margin-top:110px;font-family:"Open Sans",system-ui,-apple-system,"Segoe UI",Roboto,sans-serif}
.foot-in{max-width:1200px;margin:0 auto;padding:44px 40px 40px;display:flex;flex-wrap:wrap;gap:20px 48px;justify-content:space-between;font-size:14px;line-height:1.6;box-sizing:border-box}
.foot a{color:#fff}
.foot-name{font:400 22px/1.3 "Newsreader",Georgia,"Times New Roman",serif}
.foot p{margin:4px 0 0}
.foot-links{display:flex;flex-wrap:wrap;gap:8px 24px;list-style:none;margin:0;padding:0}
.foot-note{flex-basis:100%;opacity:.85;max-width:760px;margin:0}
@media (max-width:700px){ .foot-in{padding:36px 20px 32px} }

/* ---------- Back-to-top button (added by /assets/js/site.js) ---------- */
.to-top{position:fixed;right:24px;bottom:24px;z-index:50;width:44px;height:44px;margin:0;padding:0;border:1px solid #000;border-radius:9999px;background:#fff;color:#000;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;box-shadow:0 8px 24px rgba(0,0,0,0.12);opacity:0;visibility:hidden;transform:translateY(8px);transition:opacity 200ms cubic-bezier(0.4,0.14,0.3,1),transform 200ms cubic-bezier(0.4,0.14,0.3,1),visibility 0s linear 200ms,background 200ms}
.to-top.is-shown{opacity:1;visibility:visible;transform:none;transition:opacity 200ms cubic-bezier(0,0,0.3,1),transform 200ms cubic-bezier(0,0,0.3,1),visibility 0s,background 200ms}
.to-top:hover{background:#a6d7f0}
.to-top:focus-visible{outline:2px solid #12647e;outline-offset:2px}
.to-top:active{transform:scale(.98)}
@media (max-width:640px){ .to-top{right:16px;bottom:16px} }
@media print{ .to-top,.site-search,.search-link{display:none !important} }
@media (prefers-reduced-motion:reduce){
  .to-top,.to-top.is-shown{transform:none;transition:opacity 120ms linear,visibility 0s linear 120ms}
}
