:root {
  --accent: #eea304;
  --accent-dark: #b87a00;
  --ink: #2a2a2a;
  --muted: #666;
  --bg: #f4f4f2;
  --card: #fff;
  --line: #e2e2dd;
  --dark: #25262a;
  --radius: 10px;
  --wrap: 1120px;
  --font: -apple-system, BlinkMacSystemFont, Segoe, "Segoe UI", "DejaVu Sans", "Trebuchet MS", Verdana, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 16px/1.6 var(--font);
  color: var(--ink);
  background: var(--bg);
}
img { max-width: 100%; height: auto; }
a { color: var(--ink); text-decoration: none; text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration: underline; }
a:hover { color: var(--accent-dark); }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: clamp(1.6rem, 4vw, 2.2rem); color: #eea304; }   /* orange, as on the old site */
h2 { font-size: clamp(1.25rem, 3vw, 1.6rem); }
p { margin: 0 0 1em; }
ul { padding-left: 1.2em; list-style-type: square; }   /* square bullets everywhere (nested lists too) */
ul ul { list-style-type: square; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }

/* header */
.site-header { background: var(--dark); position: sticky; top: 0; z-index: 10; }
.bar { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; }
.brand img { display: block; }
.nav { display: flex; gap: 4px; }
.nav a {
  color: #fff; text-decoration: none; font-weight: 600; font-size: .95rem;
  padding: 8px 14px; border-radius: 6px;
}
.nav a:hover { background: rgba(255,255,255,.12); color: #fff; }
.nav a.current { background: var(--accent); color: #000; }
.nav-toggle { position: absolute; opacity: 0; pointer-events: none; }
.burger { display: none; width: 44px; height: 44px; cursor: pointer; flex-direction: column; justify-content: center; gap: 5px; padding: 0 10px; }
.burger span { display: block; height: 3px; background: #fff; border-radius: 2px; }
.nav-toggle:focus-visible + .burger { outline: 2px solid var(--accent); }

@media (max-width: 760px) {
  .burger { display: flex; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; background: var(--dark); padding: 8px 16px 16px;
    border-top: 1px solid rgba(255,255,255,.1);
  }
  .nav a { padding: 12px 14px; }
  .nav-toggle:checked ~ .nav { display: flex; }
}

/* slogan strip: the 746x117 picture at natural size, extended to the right with the grey of its right edge */
.hero, .banner {
  width: calc(100% - 32px); max-width: calc(var(--wrap) - 32px); margin: 0 auto;
  background: #e6e6e6 left top no-repeat;      /* the picture itself comes from an inline style */
}
/* full-width grey band; the picture sits in the content column inside it */
.strip { background: #e6e6e6; }
.banner { height: 117px; }
.hero { position: relative; height: 117px; color: #333; }
.hero-pic { position: absolute; left: 0; top: 0; right: 0; bottom: 0; background: left top no-repeat; }
.hero-text {
  position: absolute; right: 20px; top: 0; bottom: 0; width: min(460px, 56%);
  display: flex; flex-direction: column; justify-content: center; text-align: right;
}
.hero-text h1 { color: #333; font-size: 1.15rem; line-height: 1.25; margin: 0 0 .3em; }
.hero-text p { font-size: .85rem; line-height: 1.35; margin: 0; }
.hero-actions { max-width: calc(var(--wrap) - 32px); margin: 16px auto 0; padding: 0 16px; display: flex; justify-content: flex-end; }
@media (max-width: 800px) {
  /* phones: the picture is stretched over the full width as a strip, the text sits below it (no overlap) */
  .hero, .banner { width: 100%; max-width: none; background-size: cover; background-position: left center; }
  .banner { height: 90px; }
  .hero { height: auto; background-color: #e6e6e6; }
  .hero-pic { position: static; height: 90px; background-size: cover; background-position: left center; }
  .hero-text { position: static; width: auto; padding: 14px 16px; }
  .hero-actions { justify-content: stretch; }
}
.btn {
  display: inline-block; background: var(--accent); color: #000; font-weight: 700;
  padding: 12px 22px; border-radius: 8px; text-decoration: none;
}
.btn:hover { background: #ffb81f; color: #000; }
.btn.ghost { background: transparent; color: var(--ink); border: 2px solid #aaa; padding: 10px 20px; }
.btn.ghost:hover { background: rgba(0,0,0,.06); color: var(--ink); }

/* sections */
.section { padding: clamp(32px, 6vw, 64px) 0; }
.section.alt { background: #fff; }
.section-title { margin-bottom: 1.2em; }
/* heading decorations: img/h1.svg (orange) under h1, img/gray.svg under h2
   (the line sits at y=28 in h1.svg and y=16 in gray.svg, so the pictures are shifted up to show only the line) */
main h1::after { content: ""; display: block; width: 281px; max-width: 100%; height: 9px; margin-top: 8px; background: url(../img/h1.svg) 0 -28px no-repeat; }
main h2::after { content: ""; display: block; width: 175px; max-width: 100%; height: 7px; margin-top: 6px; background: url(../img/gray.svg) 0 -16px no-repeat; }
/* headings inside cards, update entries, login and the slogan strip stay plain */
.card h2::after, .card h1::after, .upd-entry h2::after, .hero-text h1::after { display: none; }

.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px;
}
.card.product {
  display: flex; gap: 16px; align-items: flex-start; text-decoration: none; color: inherit;
  transition: box-shadow .15s, transform .15s, border-color .15s;
}
.card.product:hover { box-shadow: 0 6px 20px rgba(0,0,0,.1); transform: translateY(-2px); border-color: var(--accent); color: inherit; }
.card.product img { flex: none; }
.card.product h3 { margin: 0; font-size: 1.2rem; color: var(--accent-dark); }
.card.product h4 { margin: 2px 0 8px; font-size: .95rem; font-weight: 600; }
.card.product p { margin: 0; font-size: .92rem; color: var(--muted); }

.two-col { display: grid; gap: 32px; grid-template-columns: 1.4fr 1fr; align-items: start; }
@media (max-width: 800px) { .two-col { grid-template-columns: 1fr; } }

.badges { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; margin-top: 12px; }
.badges img { border: 1px solid var(--line); border-radius: 4px; background: #fff; }

/* contacts */
.office h3 { color: var(--accent-dark); margin-bottom: .4em; }
.office ul { list-style: none; padding: 0; margin: 0; }
.office li { padding: 2px 0; }
/* icons come from icons.css (BookedIcons font) */
.office .booked-icon { display: inline-block; width: 1.5em; color: var(--accent-dark); }

/* clients */
.clients { columns: 3 260px; column-gap: 32px; list-style: none; padding: 0; margin: 0; font-size: .92rem; }
.clients li { break-inside: avoid; padding: 3px 0; }
.clients-group { margin-bottom: 28px; }
.refs { display: flex; flex-wrap: wrap; gap: 10px; }
.refs img { border: 1px solid #999; background: #fff; }

.steps { counter-reset: s; list-style: none; padding: 0; }
.steps li { counter-increment: s; position: relative; padding: 0 0 14px 44px; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent); color: #000; font-weight: 700; display: grid; place-items: center; font-size: .9rem;
}

/* footer */
.site-footer { background: var(--dark); color: #c9c9c9; padding: 28px 0; font-size: .9rem; }
.site-footer p { margin: 8px 0 0; }
.site-footer strong { color: var(--accent); }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.foot-links a { color: #c9c9c9; text-decoration: none; }
.foot-links a:hover { color: var(--accent); }

.preview-note {
  background: #fff3cd; color: #5c4400; font-size: .85rem; text-align: center; padding: 6px 16px;
  border-bottom: 1px solid #ecd58a;
}

/* updates */
.muted { color: var(--muted); }
.err { color: #b00020; font-weight: 600; }
.login { margin-bottom: 28px; }
.login h2 { margin-bottom: .4em; }
.login-row { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: end; }
.login-row label { display: flex; flex-direction: column; font-size: .85rem; gap: 4px; flex: 1 1 180px; }
.login-row label.check { flex-direction: row; align-items: center; flex: 0 0 auto; }
input[type=text], input[type=password] {
  font: inherit; padding: 9px 11px; border: 1px solid #bbb; border-radius: 6px; background: #fff; width: 100%;
}
input:focus-visible, button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
button.btn { border: 0; cursor: pointer; font: inherit; font-weight: 700; }
.btn.small { padding: 3px 12px; font-size: .85rem; margin-left: 6px; }

/* cookie consent banner */
.cookie-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 500;
  background: var(--dark); color: #fff;
  padding: 14px 16px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 20px;
  box-shadow: 0 -2px 12px rgba(0,0,0,.25);
}
.cookie-bar p { margin: 0; font-size: .9rem; max-width: 60ch; }
.cookie-bar a { color: var(--accent); }
.cookie-bar .btn.small { margin: 0; padding: 7px 18px; font-size: .9rem; flex: none; }
@media (max-width: 560px) { .cookie-bar { justify-content: flex-start; text-align: left; } }
.userbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 4px; margin: 0 0 20px; }

.upd-layout { display: grid; grid-template-columns: 240px 1fr; gap: 28px; align-items: start; }
.upd-side { }
.upd-group { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 12px; padding: 4px 14px 8px; }
.upd-group summary { font-weight: 700; cursor: pointer; padding: 8px 0; }
.upd-list { list-style: none; margin: 0; padding: 0; border-top: 1px dotted var(--line); }
.upd-list:first-of-type { border-top: 0; }
.upd-list li { display: flex; justify-content: space-between; gap: 8px; padding: 2px 0; font-size: .92rem; }
.upd-list .ver { color: var(--muted); font-size: .8rem; align-self: center; }
.upd-entry { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px; margin-bottom: 16px; }
.upd-entry header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; margin-bottom: 8px; }
.upd-entry h2 { margin: 0; font-size: 1.15rem; }
.upd-entry h2 a { text-decoration: none; }
.upd-entry time { color: var(--muted); font-size: .85rem; }
.upd-entry ul { margin: 0; }
.upd-entry li { margin: 3px 0; }
.upd-entry li.test { color: #a00; }
.badges-row { margin-left: auto; display: flex; gap: 10px; font-size: .85rem; }
.badge { text-decoration: none; white-space: nowrap; color: var(--muted); }
.writer {
  display: inline-block; background: #eee; color: #000; font-size: 10px; line-height: 1.5;
  border-right: 4px solid #ccc; padding: 0 3px 0 1px; margin-left: 4px; white-space: nowrap;
}
.writer a { text-decoration: none; }

@media (max-width: 860px) {
  .upd-layout { grid-template-columns: 1fr; }
  .upd-side { position: static; max-height: none; }
  .upd-group:not(:first-child) { }
}

/* product pages (converted from the old float layout) */
.legacy { display: flex; flex-wrap: wrap; gap: 8px 28px; align-items: flex-start; }
.legacy > .lg-top, .legacy > .lg-top2, .legacy > .lg-devider, .legacy > .lg-thumbnails { flex: 1 1 100%; min-width: 0; }
.legacy > .lg-devider { flex-basis: 100%; }
.legacy > .lg-devider:empty { height: 0; }   /* a divider that holds content (e.g. a heading) keeps its height */
.legacy > .lg-left, .legacy > .lg-middle, .legacy > .lg-right { flex: 1 1 260px; min-width: 0; }
.legacy > .lg-left3, .legacy > .lg-right3 { flex: 1 1 340px; min-width: 0; }
.legacy h1 { margin-top: .4em; }
.legacy h2 { margin: 1em 0 .4em; font-size: 1.2rem; }
.legacy h3 { margin: 0 0 .6em; font-size: 1rem; color: var(--muted); font-weight: 600; }
.legacy span { color: var(--accent-dark); font-weight: 700; }
.legacy hr { border: 0; border-top: 1px dotted #aaa; margin: 14px 0; }
.legacy li { margin: 3px 0; }
.legacy table { max-width: 100%; }
.legacy img[align=right] { float: right; margin: 0 0 8px 16px; max-width: 40%; height: auto; }
.legacy img[align=left] { float: left; margin: 0 16px 8px 0; max-width: 40%; height: auto; }
.box { float: right; margin: 0 0 12px 20px; max-width: 30%; height: auto; }
.lg-top::after, .lg-top2::after { content: ""; display: block; clear: both; }
@media (max-width: 560px) {
  /* small pictures stay in the text (floated, text wraps around them); only a bit smaller on phones */
  .legacy img[align] { max-width: 32%; }
  .box { float: none; display: block; margin: 0 auto 12px; max-width: 60%; }
}
.screens { flex: 1 1 100%; display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; padding: 16px 0; }
.screens img { border: 1px solid var(--line); border-radius: 6px; background: #fff; max-width: 100%; height: auto; display: block; }
a.zoom { cursor: zoom-in; }
.lightbox { position: fixed; inset: 0; background: rgba(0,0,0,.85); display: grid; place-items: center; z-index: 100; cursor: zoom-out; padding: 16px; }
.lightbox img { max-width: 100%; max-height: 100%; background: #fff; }

/* per-product updates page */
.crumbs { margin: 0 0 8px; font-size: .9rem; }
.prod-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 8px 16px; }
.warn { background: #fff3cd; border: 1px solid #ecd58a; border-radius: 8px; padding: 10px 14px; color: #8a0000; }
.file-group { margin-bottom: 16px; padding: 14px 18px; }
.file-group h3 { margin: 0 0 8px; font-size: 1rem; }
table.files { width: 100%; border-collapse: collapse; font-size: .92rem; table-layout: fixed; }
table.files td { padding: 6px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.files tr:last-child td { border-bottom: 0; }
table.files tr.latest td { background: #fdf3d4; }
table.files td:first-child { word-break: break-word; }
table.files td.r { text-align: right; white-space: nowrap; color: var(--muted); }
table.files td:nth-child(2) { width: 120px; }
table.files td:nth-child(3) { width: 130px; }
details.older > summary { cursor: pointer; font-weight: 600; margin: 8px 0 14px; }
@media (max-width: 560px) {
  /* narrow screens: name on its own line; size on the left and date on the right below it */
  table.files, table.files tbody, table.files tr, table.files td { display: block; width: auto; }
  table.files tr { padding: 6px 10px; border-bottom: 1px solid var(--line); }
  table.files tr:last-child { border-bottom: 0; }
  table.files td { padding: 0; border: 0; }
  table.files tr { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; }
  table.files td:nth-child(1) { flex: 1 1 100%; }
  table.files td:nth-child(2), table.files td:nth-child(3) { width: auto; font-size: .8rem; }
  table.files td:nth-child(2) { text-align: left; }
  table.files td:nth-child(3) { text-align: right; }
  table.files tr.latest { background: #fdf3d4; border-radius: 6px; }
  table.files tr.latest td { background: none; }
}

/* box and thumbnail pictures have a white background: multiply lets the page colour show through */
.box, .screens img, .card.product img, .legacy img[align] { mix-blend-mode: multiply; }
.screens img { background: none; border: 0; border-radius: 0; }

.btns { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 560px) { .btns .btn { flex: 1 1 100%; text-align: center; } }

.stores { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 20px; }
.stores img { display: block; }

/* narrow screens: store badges side by side, compact user bar */
.stores a { flex: 0 1 169px; min-width: 0; }
.stores img { width: 100%; height: auto; }
@media (max-width: 560px) {
  .userbar .lbl { display: none; }
  .userbar .btn.small { margin-left: 2px; padding: 3px 10px; }
  .stores { flex-wrap: nowrap; gap: 8px; }
}


/* text pages (terms) and sitemap */
.prose { max-width: 860px; }
.prose p { margin: 0 0 1em; }
.prose h2 { margin-top: 1.6em; }
.sitemap ul { margin: 0 0 1em; padding-left: 1.3em; }
.sitemap li { margin: .35em 0; }
.sitemap ul ul { margin: .35em 0 .5em; }


/* download links (presentations etc.) */
.dl-list { display: grid; gap: 10px; }
.dl { display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; }
.dl:hover { border-color: var(--accent); }
.dl .booked-icon { font-size: 1.6rem; color: var(--accent-dark); flex: none; }
.dl-name { font-weight: 600; word-break: break-word; }
.dl-meta { margin-left: auto; color: var(--muted); font-size: .85rem; white-space: nowrap; }
@media (max-width: 560px) { .dl { flex-wrap: wrap; } .dl-meta { margin-left: 2.4rem; flex-basis: 100%; } }


/* text on the left, small pictures on the right: the text takes all the free width */
.two-col.wide { grid-template-columns: 1fr auto; }
.two-col.wide .badges { margin-top: 0; }
@media (max-width: 800px) { .two-col.wide { grid-template-columns: 1fr; } }


/* four equal columns on wide screens, two on tablets, one on phones */
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1000px) { .grid.cols-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .grid.cols-4 { grid-template-columns: 1fr; } }


/* two equal halves */
.two-col.half { grid-template-columns: 1fr 1fr; }
@media (max-width: 800px) { .two-col.half { grid-template-columns: 1fr; } }


/* open/close arrows of the collapsible blocks come from the icon font (needs icons.css) */
.upd-group > summary, details.older > summary { list-style: none; display: flex; align-items: center; gap: .5em; }
.upd-group > summary::-webkit-details-marker, details.older > summary::-webkit-details-marker { display: none; }
.upd-group > summary::before, details.older > summary::before {
  font-family: 'BookedIcons'; content: '\f019'; color: var(--accent-dark); font-size: .9em; width: 1em; text-align: center;
}
.upd-group[open] > summary::before, details.older[open] > summary::before { content: '\f01b'; }
.badge .booked-icon { color: var(--muted); }

/* links that are buttons, cards or menu items keep no underline on hover */
.nav a:hover, .btn:hover, .brand:hover, .card.product:hover, .dl:hover, .foot-links a:hover, .badge:hover, .upd-entry h2 a:hover, .stores a:hover, a.zoom:hover { text-decoration: none; }

/* footer logo */
.foot-logo { display: inline-block; margin-bottom: 14px; }
.foot-logo img { display: block; height: 40px; width: auto; }

.brand img { height: 28px; width: auto; display: block; }

/* footer: symbol on the left, links and copyright to its right */
.site-footer .wrap { display: flex; align-items: center; gap: 20px; }
.foot-logo { margin: 0; flex: none; }
.foot-text { min-width: 0; }

/* phones: the big box picture at the top of a product page only takes room - hide it (the small ones in the cards stay) */
@media (max-width: 560px) {
  .box { display: none; }
}

/* headings next to a floated picture: keep the decoration line beside the picture, not under it */
.legacy h1, .legacy h2 { display: flow-root; }

/* phones: screenshot thumbnails two per row */
@media (max-width: 560px) {
  .screens { gap: 10px; }
  .screens > a, .screens > img { flex: 0 0 calc(50% - 5px); max-width: calc(50% - 5px); }
  .screens img { width: 100%; height: auto; }
}
