/* Product Factory: mobile-first. Fonts are loaded from <link> tags in each page's <head>. */
:root {
  --ink: #12181b;
  --ink-2: #1b2428;
  --paper: #eef0f1;
  --white: #fff;
  --line: #d3d9dc;
  --text: #3f484d;
  --muted: #667076;
  --bulb: #ff6b45;
  --bulb-deep: #b5380f;
  --brass: #c9a45c;
  --teal: #00a4bd;
  --display: 'Lexend Deca', 'Avenir Next', system-ui, sans-serif;
  --body: 'Inter', -apple-system, 'Avenir Next', system-ui, sans-serif;
  --gutter: clamp(20px, 5vw, 40px);
  --header-h: 64px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 12px); }
body { margin: 0; font-family: var(--body); font-size: 17px; line-height: 1.6; color: var(--text); background: var(--paper); }
img { max-width: 100%; display: block; }

h1, h2, h3, h4 { font-family: var(--display); color: var(--ink); font-weight: 600; line-height: 1.12; letter-spacing: -0.02em; margin: 0 0 16px; text-wrap: balance; }
h1 { font-size: clamp(2.3rem, 9vw, 4.6rem); font-weight: 700; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.7rem, 5.4vw, 2.8rem); }
h3 { font-size: 1.2rem; letter-spacing: -0.01em; margin-bottom: 8px; }
h4 { font-size: 0.9rem; font-family: var(--body); font-weight: 600; letter-spacing: 0; color: #9aa4a9; margin-bottom: 14px; }
p { margin: 0 0 1em; max-width: 62ch; }
a { color: var(--ink); text-underline-offset: 3px; }
a:hover { color: var(--bulb-deep); }
ul, ol { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: 6px; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 780px; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--ink); border-bottom: 1px solid rgba(255,255,255,.08); }
.site-header .bar { display: flex; align-items: center; gap: 12px; height: var(--header-h); }
.nav-brand { display: flex; align-items: center; margin-right: auto; min-height: 44px; }
.nav-brand img { height: 32px; width: auto; }
.nav-links { position: absolute; left: 0; right: 0; top: var(--header-h); background: var(--ink); padding: 8px var(--gutter) 24px; display: none; flex-direction: column; border-bottom: 1px solid rgba(255,255,255,.1); max-height: calc(100svh - var(--header-h)); overflow-y: auto; }
.nav-links.open { display: flex; }
.nav-links a { color: #fff; text-decoration: none; font-family: var(--display); font-size: 1.5rem; font-weight: 500; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.09); min-height: 52px; }
.nav-links a:hover { color: var(--bulb); }
.nav-toggle { width: 44px; height: 44px; border: 0; background: transparent; color: #fff; cursor: pointer; display: grid; place-items: center; border-radius: 8px; }
.nav-toggle i, .nav-toggle i::before, .nav-toggle i::after { display: block; width: 22px; height: 2px; background: #fff; border-radius: 2px; transition: transform .2s, opacity .2s; content: ""; }
.nav-toggle i { position: relative; }
.nav-toggle i::before { position: absolute; top: -7px; }
.nav-toggle i::after { position: absolute; top: 7px; }
.nav-toggle[aria-expanded="true"] i { background: transparent; }
.nav-toggle[aria-expanded="true"] i::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] i::after { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px; border-radius: 999px; font: 600 1rem/1 var(--body); text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: background .15s, border-color .15s, color .15s; }
.btn-primary { background: var(--bulb); color: var(--ink); }
.btn-primary:hover { background: #ff8663; color: var(--ink); }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: #fff; }
.btn-lg { min-height: 54px; padding: 0 28px; }
.site-header .btn { min-height: 44px; padding: 0 18px; font-size: .9rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* ---------- Hero ---------- */
.hero { padding: 56px 0 48px; background: var(--ink); color: #fff; }
.hero-dark { position: relative; overflow: hidden; isolation: isolate; display: flex; align-items: flex-end; min-height: clamp(460px, 78svh, 700px); padding: 0; }
.hero-dark > .container { position: relative; z-index: 2; padding-top: 96px; padding-bottom: clamp(40px, 8vw, 72px); }
.hero-dark h1 { color: #fff; max-width: 14ch; }
.hero-dark .lede, .hero-dark p { color: rgba(255,255,255,.82); max-width: 52ch; }
.lede { font-size: clamp(1.05rem, 2.6vw, 1.3rem); line-height: 1.55; }
.hero-art { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; object-fit: cover; object-position: center; filter: saturate(.9) contrast(1.05); }
.hero-art.product { object-position: right center; opacity: .95; }
.hero-dark::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(0deg, rgba(18,24,27,.94) 0%, rgba(18,24,27,.62) 45%, rgba(18,24,27,.3) 100%); }
.hero-dark::before { content: ""; position: absolute; z-index: 1; width: 90vmax; height: 90vmax; right: -30vmax; top: -45vmax; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(255,107,69,.4), rgba(255,107,69,0) 60%); animation: warm 2.4s ease-out both; }
@keyframes warm { from { opacity: 0; transform: scale(.7); } to { opacity: 1; transform: none; } }
.hero-dark .breadcrumb, .hero-dark .breadcrumb a { color: rgba(255,255,255,.65); font-size: .9rem; text-decoration: none; }
.hero-dark .breadcrumb a:hover { color: #fff; text-decoration: underline; }
.breadcrumb { margin-bottom: 18px; }
.eyebrow { display: block; font-size: 1rem; font-weight: 500; color: var(--bulb); margin-bottom: 12px; }
.hero-dark .btn-secondary { color: #fff; border-color: rgba(255,255,255,.55); }
.hero-dark .btn-secondary:hover { background: #fff; color: var(--ink); }

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 10vw, 104px) 0; }
.section-alt { background: var(--white); }
.section-head { margin-bottom: clamp(28px, 5vw, 48px); max-width: 60ch; }
.section-head p { font-size: 1.1rem; margin-bottom: 0; }

/* Plain cards on content pages: ruled items, no boxes */
.card-grid { display: grid; gap: 28px 32px; grid-template-columns: 1fr; }
.card { display: flex; flex-direction: column; align-items: flex-start; border-top: 2px solid var(--ink); padding-top: 18px; }
.card p { flex: 1; color: var(--text); }
.card-tag { display: block; font-size: .92rem; font-weight: 500; color: var(--bulb-deep); margin-bottom: 8px; }
.section-alt .card { border-top-color: var(--ink); }
.two-col { display: grid; gap: 32px; grid-template-columns: 1fr; }

/* Service tiles (photographs) */
.tiles, .panels { display: grid; gap: 14px; grid-template-columns: 1fr; }
.tiles .card { position: relative; isolation: isolate; overflow: hidden; border: 0; border-radius: 18px; padding: 0; min-height: 420px; justify-content: flex-end; background: var(--ink); color: #fff; }
.tiles .card-media-wrap { position: absolute; inset: 0; z-index: -2; margin: 0; width: 100%; height: 100%; }
.tiles .card-media { width: 100%; height: 100%; object-fit: cover; filter: saturate(.9); transition: transform .5s ease; }
.tiles .card:hover .card-media { transform: scale(1.04); }
.tiles .card::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(0deg, rgba(18,24,27,.95) 0%, rgba(18,24,27,.72) 48%, rgba(18,24,27,.1) 100%); }
.tiles .card > :not(.card-media-wrap) { margin-left: 22px; margin-right: 22px; }
.tiles .card .card-tag { color: var(--brass); }
.tiles h3 { color: #fff; font-size: 1.45rem; }
.tiles p { color: rgba(255,255,255,.86); flex: 0 0 auto; font-size: 1rem; }
.tiles .btn { margin: 4px 22px 22px; color: #fff; border-color: rgba(255,255,255,.6); background: transparent; }
.tiles .btn:hover { background: #fff; color: var(--ink); }

/* Product panels (illustrations) */
.panels .card { border: 0; border-radius: 18px; padding: 0 0 22px; background: var(--ink-2); color: #fff; overflow: hidden; }
.panels .card-media-wrap { position: relative; width: 100%; height: auto; aspect-ratio: 16 / 10; margin: 0 0 18px; }
.panels .card-media { width: 100%; height: 100%; object-fit: cover; }
.panels .card > :not(.card-media-wrap) { margin-left: 20px; margin-right: 20px; }
/* Product panels: logo as the header image */
.panels .card-media-wrap { display: flex; align-items: center; justify-content: center; background: radial-gradient(120% 90% at 50% 0%, #17343a 0%, #0f1c20 60%, #0b1417 100%); }
.panels .card-media { display: none; }
.panel-logo { width: 88px; height: 88px; border-radius: 20px; box-shadow: 0 0 0 1px rgba(255,255,255,.14), 0 10px 30px rgba(0,0,0,.5); }
.panel-logo.on-light { background: #fff; padding: 18px; box-sizing: border-box; }
.panel-logo.wordmark { width: 168px; height: 76px; padding: 14px 22px; }
.panels .card > a.btn { align-self: center; margin-left: auto; margin-right: auto; min-width: 150px; justify-content: center; text-align: center; }
.panels h3 { color: #fff; }
.panels p { color: rgba(255,255,255,.78); font-size: .98rem; }
.panels .card-tag { color: var(--brass); }
.panels .btn { margin-top: 4px; color: #fff; border-color: rgba(255,255,255,.55); background: transparent; }
.panels .btn:hover { background: #fff; color: var(--ink); }

/* Steps: a real sequence, so numbers stay */
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; display: grid; gap: 0; }
.steps li { counter-increment: step; position: relative; padding: 20px 0 20px 56px; margin: 0; border-top: 1px solid var(--line); color: var(--ink); }
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 18px; font: 600 1.7rem/1 var(--display); color: var(--bulb-deep); }
.checklist { list-style: none; padding: 0; }
.checklist li { padding-left: 28px; position: relative; }
.checklist li::before { content: ""; position: absolute; left: 2px; top: .5em; width: 12px; height: 7px; border-left: 2.5px solid var(--bulb-deep); border-bottom: 2.5px solid var(--bulb-deep); transform: rotate(-45deg); }
.callout { border-left: 4px solid var(--bulb); padding: 4px 0 4px 20px; }
.callout p:last-child { margin-bottom: 0; }
.logo-row { display: flex; flex-wrap: wrap; gap: 10px 28px; font-family: var(--display); font-weight: 500; color: var(--ink); font-size: 1.05rem; }

/* ---------- CTA band + form ---------- */
.cta-band { background: var(--ink); color: #fff; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.8); }
.cta-band .btn-secondary { color: #fff; border-color: rgba(255,255,255,.55); }
.cta-band a:not(.btn) { color: #fff; }
.cta-grid { display: grid; gap: 32px; grid-template-columns: 1fr; align-items: start; }
.cta-alt { font-size: .95rem; }
.contact-form { background: #fff; border-radius: 20px; padding: clamp(20px, 5vw, 32px); color: var(--ink); }
.contact-form .field { margin-bottom: 16px; }
.contact-form label { display: block; font-size: .92rem; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.contact-form .opt { font-weight: 400; color: var(--muted); }
.contact-form input[type="text"], .contact-form input[type="email"], .contact-form textarea { width: 100%; font: inherit; font-size: 16px; color: var(--ink); min-height: 48px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; }
.contact-form textarea { resize: vertical; min-height: 140px; }
.contact-form input:focus, .contact-form textarea:focus { outline: 3px solid rgba(0,164,189,.35); border-color: var(--teal); }
.contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-form button { width: 100%; }
.contact-form button[disabled] { opacity: .6; cursor: default; }
.contact-form .form-status { margin: 14px 0 0; font-size: .95rem; color: var(--text); min-height: 1.4em; }
.contact-form .form-status.ok { color: #0a7a3d; font-weight: 600; }
.contact-form .form-status.err { color: #b3261e; font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: rgba(255,255,255,.75); padding: 56px 0 28px; border-top: 1px solid rgba(255,255,255,.08); }
.footer-cols { display: grid; gap: 32px 24px; grid-template-columns: 1fr 1fr; margin-bottom: 40px; }
.footer-cols .footer-col:first-child { grid-column: 1 / -1; }
.footer-col h4 { color: var(--brass); font-size: .98rem; font-weight: 700; }
.footer-col a { display: block; color: rgba(255,255,255,.82); font-size: .98rem; text-decoration: none; padding: 9px 0; }
.footer-col a:hover { color: var(--bulb); }
.footer-col p { font-size: .95rem; max-width: 34ch; color: rgba(255,255,255,.7); }
.footer-col a.nav-brand { padding: 0; min-height: 0; height: 32px; margin: -8px 0 16px; }
.footer-col .nav-brand img { height: 32px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 20px; font-size: .85rem; color: rgba(255,255,255,.55); }

/* ---------- Phones: swipeable rows ---------- */
@media (max-width: 719px) {
  .tiles, .panels { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: 84%; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px;
    margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 8px; scrollbar-width: none; overscroll-behavior-x: contain; }
  .tiles::-webkit-scrollbar, .panels::-webkit-scrollbar { display: none; }
  .tiles .card, .panels .card { scroll-snap-align: center; }
  .tiles .card { min-height: 460px; }
  .hero-dark h1 { max-width: 11ch; }
}

/* ---------- Tablet ---------- */
@media (min-width: 720px) {
  body { font-size: 18px; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr 1fr; gap: 40px; }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .panels { grid-template-columns: repeat(2, 1fr); }
  .footer-cols { grid-template-columns: repeat(3, 1fr); }
  .footer-cols .footer-col:first-child { grid-column: 1 / -1; }
  .cta-grid { grid-template-columns: 1fr 1.05fr; gap: 56px; }
  .contact-form button { width: auto; }
}

/* ---------- Desktop ---------- */
@media (min-width: 1000px) {
  :root { --header-h: 72px; }
  .site-header .nav-brand img { height: 44px; }
  .nav-toggle { display: none; }
  .nav-links { position: static; display: flex; flex-direction: row; gap: 28px; padding: 0; border: 0; background: transparent; max-height: none; overflow: visible; margin: 0 auto; }
  .nav-links a { font-family: var(--body); font-size: .98rem; font-weight: 700; padding: 8px 0; border: 0; min-height: 0; color: rgba(255,255,255,.85); }
  .nav-brand { margin-right: 0; }
  .site-header .btn { margin-left: 0; }
  .card-grid { grid-template-columns: repeat(3, 1fr); }
  .tiles { grid-template-columns: repeat(6, 1fr); }
  .tiles .card { grid-column: span 2; min-height: 460px; }
  .tiles .card:nth-child(n+4) { grid-column: span 3; }
  .panels { grid-template-columns: repeat(4, 1fr); }
  .footer-cols { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
  .footer-cols .footer-col:first-child { grid-column: auto; }
  .hero-dark h1 { max-width: 15ch; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* Keep the header on one line on narrow phones */
.site-header .btn { white-space: nowrap; }
@media (max-width: 400px) {
  .site-header .nav-brand img { height: 28px; }
  .site-header .btn { padding-left: 16px; padding-right: 16px; }
}

/* ---------- Glass ---------- */
.site-header { background: rgba(18,24,27,.72); -webkit-backdrop-filter: blur(16px) saturate(1.4); backdrop-filter: blur(16px) saturate(1.4); border-bottom-color: rgba(255,255,255,.1); }
@media (max-width: 999px) { .nav-links { background: rgba(18,24,27,.92); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); } }

/* Secondary buttons on dark backgrounds */
.hero-dark .btn-secondary, .cta-band .btn-secondary, .panels .btn { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.28); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.hero-dark .btn-secondary:hover, .cta-band .btn-secondary:hover, .panels .btn:hover { background: rgba(255,255,255,.2); color: #fff; }

/* Photo tiles: the photo melts into a frosted pane behind the text */
.tiles .card::before { background: linear-gradient(0deg, rgba(18,24,27,.88) 0%, rgba(18,24,27,.55) 55%, rgba(18,24,27,0) 100%); -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2); -webkit-mask-image: linear-gradient(0deg, #000 58%, transparent 100%); mask-image: linear-gradient(0deg, #000 58%, transparent 100%); }

/* Products: dark stage with soft colour, glass panels */
#products { position: relative; overflow: hidden; isolation: isolate; background: #0b1417; }
#products::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 50% at 12% 0%, rgba(255,107,69,.22), transparent 70%), radial-gradient(55% 55% at 90% 100%, rgba(0,164,189,.22), transparent 70%); }
#products .section-head h2 { color: #fff; }
#products .section-head p { color: rgba(255,255,255,.72); }
.panels .card { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); box-shadow: 0 1px 0 rgba(255,255,255,.08) inset, 0 20px 50px rgba(0,0,0,.35); }
.panels .card-media-wrap { background: linear-gradient(160deg, rgba(255,255,255,.1), rgba(255,255,255,.02)); border-bottom: 1px solid rgba(255,255,255,.1); }

/* ---------- Glass buttons (all CTAs) ---------- */
.btn { -webkit-backdrop-filter: blur(10px) saturate(1.3); backdrop-filter: blur(10px) saturate(1.3); transition: background .2s ease, box-shadow .2s ease, border-color .2s ease, color .2s ease; }
.btn-primary, .btn-primary:visited { background: linear-gradient(135deg, rgba(255,120,82,.95), rgba(255,92,54,.78)); border: 1px solid rgba(255,255,255,.4); color: var(--ink); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), inset 0 -1px 0 rgba(0,0,0,.08), 0 8px 24px rgba(255,107,69,.32); }
.btn-primary:hover { background: linear-gradient(135deg, rgba(255,136,100,1), rgba(255,104,66,.88)); color: var(--ink); box-shadow: inset 0 1px 0 rgba(255,255,255,.6), 0 10px 30px rgba(255,107,69,.45); }
/* Outline buttons on light backgrounds */
.btn-secondary { background: rgba(255,255,255,.55); border: 1px solid rgba(18,24,27,.3); box-shadow: inset 0 1px 0 rgba(255,255,255,.8); }
.btn-secondary:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
/* Outline buttons on dark backgrounds */
.hero-dark .btn-secondary, .cta-band .btn-secondary, .panels .btn { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.3); box-shadow: inset 0 1px 0 rgba(255,255,255,.22); }
.hero-dark .btn-secondary:hover, .cta-band .btn-secondary:hover, .panels .btn:hover { background: rgba(255,255,255,.22); border-color: rgba(255,255,255,.5); color: #fff; }

/* Visited links must keep button colours */
.btn-secondary:visited { color: var(--ink); }
.btn-secondary:hover:visited { color: #fff; }
.hero-dark .btn-secondary:visited, .cta-band .btn-secondary:visited, .panels .btn:visited { color: #fff; }
.tiles .btn, .tiles .btn:visited { color: #fff; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.35); box-shadow: inset 0 1px 0 rgba(255,255,255,.22); }
.tiles .btn:hover, .tiles .btn:hover:visited { background: rgba(255,255,255,.24); border-color: rgba(255,255,255,.55); color: #fff; }
.btn-primary:hover:visited { color: var(--ink); }
