:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --mist: #ebf0f5;
  --graphite: #182026;
  --graphite-2: #24303a;
  --cobalt: #1d4ed8;
  --cobalt-d: #1e40af;
  --cobalt-soft: #eff6ff;
  --olive: #3f6212;
  --olive-soft: #f0f7e6;
  --ink: #111820;
  --body: #334150;
  --muted: #5a6978;
  --line: #d7dfe8;
  --line-2: #b9c5d3;
  --radius: 9px;
  --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font-sans); color: var(--body); background: var(--bg);
  font-size: 15.5px; line-height: 1.65; -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 {
  font-family: var(--font-display); color: var(--ink); font-weight: 700;
  letter-spacing: -0.025em; line-height: 1.14; margin: 0 0 0.7rem;
}
h1 { font-size: clamp(2rem, 3.8vw, 2.95rem); }
h2 { font-size: clamp(1.45rem, 2.3vw, 1.98rem); }
h3 { font-size: 1.08rem; }
p { margin: 0 0 1rem; }
a { color: var(--cobalt); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { max-width: 100%; height: auto; display: block; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.wrap-narrow { max-width: 800px; margin: 0 auto; padding: 0 20px; }
.num { font-variant-numeric: tabular-nums; }

/* Dark Graphite Top Bar + Sticky Header */
.dub-bar {
  background: var(--graphite); color: #cbd5e1; font-size: 0.79rem; font-weight: 600;
  padding: 7px 0; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.dub-bar-in { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.dub-pill { color: #a3e635; font-weight: 700; }
.hdr {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.96); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.hdr-in { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 64px; }
.wordmark {
  font-family: var(--font-display); font-weight: 700; font-size: 1.18rem;
  color: var(--graphite); letter-spacing: -0.03em; white-space: nowrap; text-decoration: none;
}
.wordmark:hover { text-decoration: none; }
.wordmark span { color: var(--cobalt); }
.hnav { display: flex; align-items: center; gap: 18px; }
.hnav a { color: var(--body); font-size: 0.89rem; font-weight: 600; }
.hnav a:hover, .hnav a[aria-current="page"] { color: var(--cobalt); text-decoration: none; }
.hact { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.menu-btn {
  display: none; background: #fff; border: 1.5px solid var(--line-2); border-radius: 7px;
  padding: 7px 11px; font-family: var(--font-display); font-size: 0.83rem; font-weight: 700; color: var(--graphite); cursor: pointer;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 20px; border-radius: 8px;
  font-family: var(--font-display); font-weight: 700; font-size: 0.94rem;
  border: 1.5px solid transparent; cursor: pointer; text-decoration: none; line-height: 1.15;
  transition: background .15s ease, border-color .15s ease;
}
.btn:hover { text-decoration: none; }
.btn-cobalt { background: var(--cobalt); color: #fff; }
.btn-cobalt:hover { background: var(--cobalt-d); color: #fff; }
.btn-dark { background: var(--graphite); color: #fff; }
.btn-dark:hover { background: var(--graphite-2); color: #fff; }
.btn-outline { background: #fff; color: var(--graphite); border-color: var(--graphite); }
.btn-outline:hover { background: var(--mist); color: var(--graphite); }
.btn-sm { min-height: 36px; padding: 0 13px; font-size: 0.82rem; }
.btn-full { width: 100%; }

/* Architectural Hero */
.hero {
  background: linear-gradient(180deg, #ffffff 0%, var(--bg) 100%);
  padding: clamp(26px, 4vw, 50px) 0 clamp(32px, 4.5vw, 52px);
  border-bottom: 1px solid var(--line);
}
.hero-split {
  display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: clamp(24px, 3.6vw, 44px); align-items: start;
}
.kicker {
  display: inline-flex; align-items: center; gap: 6px; font-size: 0.77rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em; color: var(--olive);
  background: var(--olive-soft); padding: 4px 10px; border-radius: 5px; margin-bottom: 12px;
}
.hero-lead { font-size: clamp(1rem, 1.22vw, 1.11rem); color: var(--body); max-width: 54ch; margin: 0 0 16px; }
.trust-bar {
  font-size: 0.89rem; font-weight: 600; color: var(--graphite);
  background: var(--cobalt-soft); border-left: 3.5px solid var(--cobalt);
  padding: 9px 13px; border-radius: 0 7px 7px 0; margin: 0 0 20px; max-width: 52ch;
}
.hero-links { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 22px; }
.stats-4 {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px; list-style: none; padding: 0; margin: 0;
}
.stats-4 li {
  background: #fff; border: 1px solid var(--line); border-left: 3.5px solid var(--graphite);
  border-radius: 0 8px 8px 0; padding: 11px 13px;
}
.stats-4 strong {
  display: block; font-family: var(--font-display); font-size: clamp(1.1rem, 1.45vw, 1.3rem);
  font-weight: 700; color: var(--graphite); line-height: 1.15;
}
.stats-4 span { display: block; font-size: 0.79rem; color: var(--muted); margin-top: 2px; line-height: 1.35; }

/* Dublin Per-Metre Composite Fencing Calculator Card */
.calc-card {
  background: #fff; border: 1.5px solid var(--line-2); border-top: 4px solid var(--cobalt);
  border-radius: 11px; padding: clamp(18px, 2.4vw, 25px);
  box-shadow: 0 14px 34px rgba(24, 32, 38, 0.08);
}
.calc-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 13px; }
.calc-head h2 { font-size: 1.16rem; margin: 0; color: var(--graphite); }
.calc-tag {
  font-size: 0.74rem; font-weight: 700; color: var(--olive); background: var(--olive-soft);
  padding: 3px 9px; border-radius: 99px; white-space: nowrap;
}
.c-group { margin-bottom: 13px; }
.c-lbl-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 6px; }
.c-lbl { font-size: 0.81rem; font-weight: 700; color: var(--ink); }
.c-len-wrap { display: flex; align-items: center; gap: 5px; }
.c-len-input {
  width: 68px; min-height: 36px; padding: 4px 8px; border: 1.5px solid var(--line-2); border-radius: 6px;
  font-family: var(--font-display); font-size: 1rem; font-weight: 700; text-align: center; color: var(--graphite);
}
.c-range { width: 100%; accent-color: var(--cobalt); margin: 4px 0 7px; cursor: pointer; }
.c-presets { display: flex; flex-wrap: wrap; gap: 6px; }
.c-preset {
  padding: 5px 9px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--bg);
  font-size: 0.75rem; font-weight: 600; color: var(--body); cursor: pointer;
}
.c-preset.on, .c-preset:hover { border-color: var(--cobalt); background: var(--cobalt-soft); color: var(--cobalt-d); }
.c-heights { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.c-btn {
  padding: 8px 6px; border: 1.5px solid var(--line-2); border-radius: 7px; background: #fff;
  font-family: var(--font-display); font-size: 0.86rem; font-weight: 700; color: var(--ink); cursor: pointer;
}
.c-btn[aria-pressed="true"], .c-btn:hover { border-color: var(--cobalt); background: var(--cobalt-soft); color: var(--cobalt-d); }
.c-systems { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.c-sys {
  text-align: left; padding: 8px 10px; border: 1.5px solid var(--line-2); border-radius: 7px;
  background: #fff; cursor: pointer; font-family: var(--font-sans);
}
.c-sys b { display: block; font-size: 0.82rem; color: var(--ink); line-height: 1.25; }
.c-sys small { display: block; font-size: 0.72rem; color: var(--muted); margin-top: 2px; }
.c-sys[aria-pressed="true"], .c-sys:hover { border-color: var(--cobalt); background: var(--cobalt-soft); }
.c-sys[aria-pressed="true"] b { color: var(--cobalt-d); }
.c-toggles { display: grid; gap: 7px; margin-bottom: 13px; }
.c-tog {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 7px; background: var(--bg);
  font-size: 0.82rem; cursor: pointer;
}
.c-tog-l { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ink); }
.c-tog input { width: 17px; height: 17px; accent-color: var(--cobalt); flex-shrink: 0; }
.c-tog-p { font-size: 0.77rem; font-weight: 700; color: var(--muted); white-space: nowrap; }
.c-result {
  background: var(--graphite); color: #fff; border-radius: 9px; padding: 14px 16px; margin-bottom: 12px;
}
.c-res-k { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; color: #93c5fd; }
.c-res-main { font-family: var(--font-display); font-size: clamp(1.45rem, 2.4vw, 1.85rem); font-weight: 700; color: #fff; line-height: 1.15; margin: 3px 0 4px; }
.c-res-sub { font-size: 0.84rem; font-weight: 600; color: #a3e635; margin-bottom: 5px; }
.c-res-spec { font-size: 0.78rem; color: #cbd5e1; border-top: 1px solid rgba(255,255,255,0.14); padding-top: 6px; }
.c-note { font-size: 0.78rem; color: var(--muted); text-align: center; margin: 8px 0 0; }

/* Contact Pane */
.q-price-box {
  background: var(--cobalt-soft); border-left: 4px solid var(--cobalt);
  border-radius: 0 8px 8px 0; padding: 12px 14px; margin-bottom: 12px;
}
.q-price-k { font-size: 0.73rem; font-weight: 700; text-transform: uppercase; color: var(--cobalt-d); }
.q-price-big { font-family: var(--font-display); font-size: 1.32rem; font-weight: 700; color: var(--graphite); margin: 2px 0; }
.q-price-sub { font-size: 0.81rem; color: var(--body); }
.f-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.f-field { margin-bottom: 8px; }
.f-field.full { grid-column: 1 / -1; }
.f-field label { display: block; font-size: 0.79rem; font-weight: 700; color: var(--ink); margin-bottom: 3px; }
.f-field input, .f-field select, .f-field textarea {
  width: 100%; min-height: 41px; padding: 8px 10px; border: 1.5px solid var(--line-2);
  border-radius: 7px; font-family: var(--font-sans); font-size: 0.95rem; color: var(--ink); background: #fff;
}
.f-field input:focus, .f-field select:focus, .f-field textarea:focus { outline: none; border-color: var(--cobalt); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.consent {
  display: flex; align-items: flex-start; gap: 8px; padding: 9px 10px;
  border: 1px solid var(--line); border-radius: 7px; background: var(--bg);
  font-size: 0.79rem; color: var(--body); margin: 4px 0 9px; line-height: 1.42;
}
.consent input { width: 17px; height: 17px; margin-top: 2px; accent-color: var(--cobalt); flex-shrink: 0; }
.q-nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 9px; }
.q-back { background: transparent; border: 0; color: var(--muted); font-family: var(--font-display); font-size: 0.85rem; font-weight: 700; cursor: pointer; padding: 8px 4px; }
.q-err { color: #b91c1c; font-size: 0.83rem; font-weight: 700; min-height: 1.2em; margin: 5px 0 0; }

/* Sections & Grids */
.sec { padding: clamp(40px, 5.2vw, 64px) 0; background: #fff; }
.sec.alt { background: var(--bg); }
.sec + .sec { border-top: 1px solid var(--line); }
.sec-head { max-width: 720px; margin-bottom: 24px; }
.sec-head p { color: var(--muted); margin: 0; }
.sys-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.scard {
  border: 1px solid var(--line); border-radius: 9px; overflow: hidden; background: #fff;
  display: flex; flex-direction: column;
}
.scard-img { aspect-ratio: 4 / 3; overflow: hidden; background: var(--mist); border-bottom: 1px solid var(--line); }
.scard-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.scard:hover .scard-img img { transform: scale(1.03); }
.scard-body { padding: 14px 15px 15px; display: flex; flex-direction: column; flex: 1; }
.scard-t { font-family: var(--font-display); font-size: 1rem; color: var(--graphite); margin: 0 0 3px; }
.scard-p { font-weight: 700; font-size: 0.87rem; color: var(--cobalt); margin: 0 0 7px; }
.scard-d { font-size: 0.84rem; color: var(--muted); margin: 0 0 12px; line-height: 1.48; }
.scard-act { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.scard-pick { background: none; border: 0; padding: 0; font-weight: 700; font-size: 0.82rem; color: var(--cobalt); cursor: pointer; }
.scard-pick:hover { text-decoration: underline; }
.scard-link { font-size: 0.81rem; font-weight: 600; color: var(--muted); }

/* Swatches, Council Grid, Tables, Cards */
.swatch-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.swatch { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: #fff; }
.swatch-bar { height: 48px; }
.swatch-lbl { padding: 8px 10px; font-size: 0.8rem; font-weight: 700; color: var(--ink); line-height: 1.25; }
.cards-4 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.cards-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.cards-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.fact-card { border: 1px solid var(--line); border-top: 3px solid var(--graphite); border-radius: 9px; padding: 18px; background: #fff; }
.fact-card h3 { color: var(--graphite); margin-bottom: 6px; }
.fact-card p:last-child { margin-bottom: 0; font-size: 0.92rem; }
.gcard {
  display: flex; flex-direction: column; gap: 7px; padding: 19px;
  border: 1px solid var(--line); border-radius: 9px; background: #fff; color: var(--body);
}
.gcard:hover { border-color: var(--cobalt); text-decoration: none; }
.gcard b { font-family: var(--font-display); font-size: 1.03rem; color: var(--graphite); }
.gcard span { font-size: 0.87rem; color: var(--muted); }
.gmore { margin-top: auto; padding-top: 6px; font-weight: 700; font-size: 0.84rem; color: var(--cobalt) !important; }
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: 0.91rem; }
th, td { padding: 13px 15px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--mist); font-family: var(--font-display); font-weight: 700; color: var(--graphite); font-size: 0.84rem; }
tr:last-child td { border-bottom: 0; }
.zone-box { margin-bottom: 28px; }
.zone-box h3 { color: var(--graphite); border-bottom: 2px solid var(--line); padding-bottom: 8px; margin-bottom: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 12px 0 0; }
.chips a {
  display: inline-flex; padding: 7px 12px; border: 1px solid var(--line-2); border-radius: 6px;
  color: var(--graphite); font-weight: 600; font-size: 0.85rem; background: #fff;
}
.chips a:hover { border-color: var(--cobalt); color: var(--cobalt); text-decoration: none; }
.note-box {
  border-left: 4px solid var(--olive); background: var(--olive-soft);
  padding: 15px 18px; border-radius: 0 8px 8px 0; margin: 22px 0; color: var(--ink);
}
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.82rem; color: var(--muted); margin-bottom: 12px; }
.crumbs a { color: var(--muted); }
.prose h2 { margin-top: 1.85rem; color: var(--graphite); }
.prose ul { padding-left: 20px; margin: 0 0 1.2rem; }
.prose li { margin-bottom: 0.45rem; }
.media-fig { margin: 20px 0; }
.media-fig img { width: 100%; max-height: 440px; object-fit: cover; border-radius: 9px; border: 1px solid var(--line); }
.media-fig figcaption { font-size: 0.82rem; color: var(--muted); margin-top: 7px; }

/* FAQ */
.faq-list { max-width: 840px; border-top: 1px solid var(--line); }
details.faq { border-bottom: 1px solid var(--line); padding: 14px 0; }
details.faq summary {
  font-family: var(--font-display); font-weight: 700; color: var(--graphite); cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 14px; font-size: 0.98rem;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after { content: '+'; font-size: 1.3rem; color: var(--cobalt); font-weight: 600; flex: none; }
details.faq[open] summary::after { content: '−'; }
details.faq p { margin: 9px 0 0; font-size: 0.93rem; color: var(--body); }

/* Thanks Photo Uploader */
.more-card { max-width: 650px; border: 1.5px solid var(--line-2); border-radius: 10px; padding: 24px; background: #fff; }
.more-up {
  display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 24px 16px;
  border: 2px dashed var(--line-2); border-radius: 9px; background: var(--bg);
  text-align: center; cursor: pointer; margin-bottom: 15px;
}
.more-up:hover { border-color: var(--cobalt); }
.more-up b { color: var(--graphite); }
.more-up span { font-size: 0.83rem; color: var(--muted); }
.more-thumbs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-bottom: 13px; }
.more-th { position: relative; aspect-ratio: 4 / 3; border-radius: 7px; overflow: hidden; border: 1px solid var(--line); }
.more-th img { width: 100%; height: 100%; object-fit: cover; }
.more-th button {
  position: absolute; top: 5px; right: 5px; width: 26px; height: 26px; border-radius: 50%;
  border: 0; background: rgba(24, 32, 38, 0.86); color: #fff; font-size: 16px; cursor: pointer;
}
.more-st { font-size: 0.84rem; color: var(--muted); margin: 9px 0 0; }
.more-ok { padding: 14px 16px; background: var(--olive-soft); border: 1px solid #bef264; color: var(--olive); border-radius: 8px; font-weight: 700; }

/* CTA & Footer */
.qband {
  background: var(--graphite); color: #fff; border-radius: 10px;
  padding: clamp(24px, 3.8vw, 36px); display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.qband h2 { color: #fff; margin: 0 0 6px; }
.qband p { color: #cbd5e1; margin: 0; max-width: 54ch; }
.foot { background: var(--graphite); color: #cbd5e1; padding: 48px 0 30px; font-size: 0.88rem; }
.foot .wordmark { color: #fff; }
.foot .wordmark span { color: #60a5fa; }
.foot-grid { display: grid; grid-template-columns: 1.35fr 1fr 1fr 1fr; gap: 28px; margin-bottom: 28px; }
.foot h4 { font-family: var(--font-display); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.06em; color: #fff; margin-bottom: 10px; }
.foot a { display: block; color: #cbd5e1; margin-bottom: 7px; }
.foot a:hover { color: #fff; }
.foot-legal {
  border-top: 1px solid rgba(255,255,255,0.12); padding-top: 18px;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: 0.81rem; color: #94a3b8;
}
.foot-legal a { display: inline; color: #e2e8f0; }

@media (max-width: 980px) {
  .hero-split { grid-template-columns: 1fr; }
  .sys-grid, .cards-3, .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .swatch-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hnav {
    display: none; position: absolute; left: 0; right: 0; top: 64px; background: #fff;
    border-bottom: 1px solid var(--line); padding: 16px 20px; flex-direction: column; align-items: flex-start; gap: 13px;
  }
  .hnav.open { display: flex; }
  .menu-btn { display: inline-flex; }
}
@media (max-width: 640px) {
  .sys-grid, .cards-3, .cards-2, .cards-4, .foot-grid, .f-grid, .c-systems { grid-template-columns: 1fr; }
  .swatch-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wordmark { font-size: 1.03rem; }
  .hdr .btn-sm { padding: 0 10px; font-size: 0.78rem; }
  .dub-hide { display: none; }
}
