/* Shared styles for JT Glazing sub-pages (Privacy / Terms / SiteMap). Mirrors the
   homepage design tokens. */
:root {
  --bg: #F6F7F9; --surface: #FFFFFF; --surface-2: #EEF1F5;
  --ink: #172230; --ink-2: #41505F; --muted: #697787;
  --line: #E3E7EC; --line-strong: #CCD4DD;
  --brand: #1D3A5A; --brand-2: #27507C; --on-brand: #FFFFFF;
  --accent: #2f74c0; --accent-soft: rgba(47,116,192,0.12);
  --shadow: 0 1px 2px rgba(23,34,48,.06), 0 10px 30px -14px rgba(23,34,48,.22);
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SF Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --maxw: 860px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0E141B; --surface: #151D26; --surface-2: #1C2732;
    --ink: #EAEEF3; --ink-2: #C0CAD5; --muted: #8695A5;
    --line: #263139; --line-strong: #35434F;
    --brand: #5E93C9; --brand-2: #79A9D9; --on-brand: #0B1017;
    --accent: #5aa0e6; --accent-soft: rgba(90,160,230,0.16);
    --shadow: 0 1px 2px rgba(0,0,0,.35), 0 16px 38px -16px rgba(0,0,0,.6);
  }
}
:root[data-theme="light"] { --bg:#F6F7F9;--surface:#FFF;--ink:#172230;--ink-2:#41505F;--muted:#697787;--line:#E3E7EC;--line-strong:#CCD4DD;--brand:#1D3A5A;--brand-2:#27507C;--on-brand:#FFF;--accent:#2f74c0; }
:root[data-theme="dark"] { --bg:#0E141B;--surface:#151D26;--ink:#EAEEF3;--ink-2:#C0CAD5;--muted:#8695A5;--line:#263139;--line-strong:#35434F;--brand:#5E93C9;--brand-2:#79A9D9;--on-brand:#0B1017;--accent:#5aa0e6; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--bg); }
body { margin: 0; background: transparent; color: var(--ink); font-family: var(--sans); font-size: 1.02rem; line-height: 1.65; -webkit-font-smoothing: antialiased; }

/* Fixed full-screen background photo — same treatment as the homepage, so the whole
   site shares one backdrop. It stays put while content scrolls over it. NO veil (per
   John). Sub-pages carry long-form text, so instead of white-on-photo type they sit on
   a solid .page panel that floats over the photo — the photo shows in the gutters,
   behind the header/footer, and around the panel. */
:root { --hero-photo: url('/hero-photo.jpg'); }
body::before { content: ""; position: fixed; inset: 0; z-index: -2; background: var(--hero-photo) center center / cover no-repeat; }

a { color: var(--brand); }
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: clamp(1.15rem, 4vw, 2rem); }

/* nav — solid white bar, matching the homepage header over the photo */
header.bar { position: sticky; top: 0; z-index: 40; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: 0 1px 0 rgba(23,34,48,.04), 0 6px 20px -18px rgba(23,34,48,.5); }
.bar-in { display: flex; align-items: center; gap: 1rem; height: 78px; max-width: 1120px; }
.brand-link { display: flex; text-decoration: none; }
.brand-logo { height: 60px; width: auto; max-width: 64vw; display: block; --lk: #1b2f52; --lg: #b8912f; }
@media (prefers-color-scheme: dark) { .brand-logo { --lk: #EAEEF3; --lg: #5aa0e6; } }
:root[data-theme="light"] .brand-logo { --lk: #1b2f52; --lg: #b8912f; }
:root[data-theme="dark"] .brand-logo { --lk: #EAEEF3; --lg: #5aa0e6; }
@media (max-width: 480px) { .brand-logo { height: 50px; } .bar-in { height: 66px; } }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; font-weight: 700; font-size: 0.95rem; text-decoration: none; padding: 0.62rem 1.4rem; border-radius: 8px; border: 1px solid transparent; }
.btn-emergency { margin-left: auto; background: #d62828; color: #fff; box-shadow: 0 2px 12px rgba(214,40,40,.4); }
.btn-emergency:hover { background: #b71c1c; }
.btn-emergency svg { width: 18px; height: 18px; }

/* header nav tabs (mirrors the homepage) */
.bar-nav { margin-left: auto; display: none; align-items: center; gap: 0.35rem; }
.bar-nav a { position: relative; text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: 0.92rem; padding: 0.55rem 0.85rem; border-radius: 8px; white-space: nowrap; }
.bar-nav a:hover { color: var(--brand); background: var(--surface-2); }
.bar-nav a::after { content: ""; position: absolute; left: 0.85rem; right: 0.85rem; bottom: 0.28rem; height: 2px; background: var(--accent); border-radius: 2px; transform: scaleX(0); transition: transform .2s ease; }
.bar-nav a[aria-current="page"] { color: var(--brand); }
.bar-nav a[aria-current="page"]::after { transform: scaleX(1); }
.bar .btn-emergency { margin-left: auto; }
@media (min-width: 900px) { .bar-nav { display: flex; } .bar .btn-emergency { margin-left: 0.6rem; } }
.bar-nav-mobile { display: flex; gap: 0.3rem; overflow-x: auto; padding: 0 clamp(1.15rem, 4vw, 2rem) 0.55rem; scrollbar-width: none; max-width: 1120px; margin-inline: auto; }
.bar-nav-mobile::-webkit-scrollbar { display: none; }
.bar-nav-mobile a { text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: 0.85rem; padding: 0.4rem 0.7rem; border-radius: 999px; background: var(--surface-2); white-space: nowrap; }
.bar-nav-mobile a[aria-current="page"] { color: var(--on-brand); background: var(--brand); }
@media (min-width: 900px) { .bar-nav-mobile { display: none; } }

/* wider content column for the FAQ / testimonials pages */
.page-wide { max-width: 1120px; }
.lede-intro { font-size: 1.08rem; color: var(--ink-2); margin: 0 0 2rem; max-width: 60ch; }

/* FAQ accordion */
.faq { display: grid; gap: 0.7rem; }
.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); overflow: hidden; }
.faq-item summary { cursor: pointer; list-style: none; padding: 1rem 3rem 1rem 1.15rem; font-weight: 650; color: var(--ink); position: relative; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 1.15rem; top: 50%; transform: translateY(-50%); font-size: 1.5rem; font-weight: 400; color: var(--brand); line-height: 1; }
.faq-item[open] summary::after { content: "\2212"; }
.faq-item summary:hover { color: var(--brand); }
.faq-item p { margin: 0; padding: 0.9rem 1.15rem 1.15rem; color: var(--ink-2); border-top: 1px solid var(--line); }
.faq-item p a { color: var(--brand); font-weight: 600; }

/* testimonials */
.quotes { display: grid; gap: 0.9rem; grid-template-columns: 1fr; margin: 0; padding: 0; }
@media (min-width: 700px) { .quotes { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .quotes { grid-template-columns: repeat(3, 1fr); } }
.quote { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 1.3rem 1.25rem 1.15rem; display: flex; flex-direction: column; gap: 0.8rem; margin: 0; }
.quote blockquote { margin: 0; color: var(--ink); font-size: 1.02rem; line-height: 1.55; }
.quote blockquote::before { content: "\201C"; color: var(--accent); font-size: 2.2rem; line-height: 0; vertical-align: -0.35rem; margin-right: 0.15rem; font-weight: 700; }
.quote figcaption { margin-top: auto; font-size: 0.86rem; color: var(--muted); border-top: 1px solid var(--line); padding-top: 0.7rem; }
.quote figcaption b { color: var(--ink-2); font-weight: 700; display: block; }
.quotes-empty { grid-column: 1 / -1; margin: 0; background: var(--surface); border: 1px dashed var(--line-strong); border-radius: 12px; padding: 1.4rem 1.3rem; color: var(--ink-2); }


/* service cards (ported from the homepage so /Services can use them) */
.caps { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.8rem; margin: 0; padding: 0; }
@media (min-width: 560px) { .caps { grid-template-columns: repeat(3, 1fr); } }
.cap { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 1.15rem 1.05rem 1.2rem; transition: transform .16s ease, border-color .16s ease, box-shadow .22s ease; }
.cap:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow); }
.cap .ico { width: 26px; height: 26px; color: var(--brand); margin-bottom: 0.6rem; }
.cap h3 { font-size: 1.02rem; font-weight: 700; line-height: 1.2; margin: 0; }
.cap p { margin: 0.45rem 0 0; font-size: 0.9rem; color: var(--ink-2); line-height: 1.45; }
.cap .tag { display: inline-block; margin-top: 0.75rem; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.02em; color: var(--accent); background: var(--accent-soft); padding: 0.2rem 0.5rem; border-radius: 5px; line-height: 1.25; }
.cap.lead { border-color: color-mix(in srgb, var(--brand) 35%, var(--line)); }
.cap.lead::after { content: "Specialism"; position: absolute; top: 1.1rem; right: 1.1rem; font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--brand); }

/* legal / content — the panel that floats over the background photo. Tinted rather
   than pure white so the white .cap/.faq-item/.quote cards inside still read as cards. */
main.page {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 2px 6px rgba(23,34,48,.10), 0 24px 60px -28px rgba(23,34,48,.55);
  padding-block: clamp(1.6rem, 4vw, 2.6rem);
  padding-inline: clamp(1.25rem, 4vw, 2.4rem);
  margin-block: clamp(1.4rem, 4vw, 2.6rem);
}
/* .page is also .wrap; keep the panel inset from the viewport edge on phones */
@media (max-width: 620px) { main.page { margin-inline: 0.9rem; width: auto; } }
.crumb { font-size: 0.9rem; margin: 0 0 1.5rem; }
.crumb a { text-decoration: none; color: var(--muted); }
.crumb a:hover { color: var(--brand); }
.page h1 { font-size: clamp(1.9rem, 1.4rem + 2vw, 2.6rem); font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; margin: 0 0 0.5rem; }
.page .updated { color: var(--muted); font-size: 0.9rem; margin: 0 0 2rem; }
.page h2 { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; margin: 2.4rem 0 0.7rem; padding-top: 0.6rem; }
.page h3 { font-size: 1.08rem; font-weight: 700; margin: 1.6rem 0 0.5rem; }
.page p { margin: 0 0 1rem; color: var(--ink-2); }
.page ul, .page ol { margin: 0 0 1.2rem; padding-left: 1.3rem; color: var(--ink-2); }
.page li { margin: 0.35rem 0; }
.page strong { color: var(--ink); }
.note { background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent); border-radius: 10px; padding: 1rem 1.2rem; font-size: 0.92rem; color: var(--ink-2); margin: 0 0 2rem; }

/* sitemap cards */
.sm-grid { display: grid; grid-template-columns: 1fr; gap: 1rem; margin: 1.2rem 0 0; }
@media (min-width: 620px) { .sm-grid { grid-template-columns: 1fr 1fr; } }
.sm-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 1.2rem 1.3rem; }
.sm-card h2 { margin: 0 0 0.6rem; padding: 0; font-size: 1.1rem; }
.sm-card ul { list-style: none; padding: 0; margin: 0; }
.sm-card li { margin: 0.4rem 0; }
.sm-card a { text-decoration: none; }
.sm-card a:hover { text-decoration: underline; }
.areas { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.8rem 0 0; padding: 0; list-style: none; }
.areas li { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 0.25rem 0.7rem; font-size: 0.85rem; color: var(--ink-2); }

footer { padding-block: 2rem 3rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.85rem; margin-top: 0; background: var(--surface); }
.foot-in { display: flex; flex-wrap: wrap; gap: 0.5rem 1.3rem; align-items: center; }
.foot-in a { color: var(--muted); text-decoration: none; }
.foot-in a:hover { color: var(--brand); }
.foot-in .sep { color: var(--line-strong); }
.foot-in .mono { font-family: var(--mono); margin-left: auto; font-size: 0.78rem; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
