/* ============================================================================
   POLICY — the legal pages: Privacy Policy, Cookies Policy, Terms & Conditions
   Loaded after main.css by privacy-policy.html, cookie-policy.html and
   terms-conditions.html. Scoped to .pol, prefixed .pol-.

   The sector policy pages are a different template living in
   assets/css/sector-policy.css and namespaced .sp- — the two must never share
   class names again.

   A legal document read on screen: a quiet hero, a switch between the three
   documents, a contents rail with a find-in-page filter, and one reading
   column.

   01  Tokens
   02  Hero and the document switch
   03  Layout
   04  Contents rail and the find field
   05  The document: lede, sections, prose
   06  Definitions, notes, lists
   07  Cookie cards and browser links
   08  Find-in-page states, footer
   09  Responsive
   ========================================================================= */

/* 01 ── TOKENS ────────────────────────────────────────────────────────── */

.pol{
  --pc:#2d308f;                      /* the brand blue carries these pages */
  --pol-rail:248px;
  --pol-gap:clamp(1.8rem,4.4vw,5rem);
  --pol-sec:clamp(2.4rem,4.4vw,3.6rem);
  --pol-measure:38em;
  color:var(--ink);
}

/* 02 ── HERO + SWITCH ─────────────────────────────────────────────────── */

.pol-hero{
  padding-top:calc(var(--hdr-h) + var(--util-h) + clamp(2rem,4vw,3.4rem));
  padding-bottom:clamp(1.8rem,3.4vw,2.8rem);
  background:linear-gradient(170deg,var(--paper) 0%,var(--paper-2) 100%);
  border-bottom:1px solid var(--line);
}
.pol-hero__h{
  margin:0 0 .9rem;font-family:var(--f-head);font-weight:700;
  font-size:clamp(1.9rem,3.8vw,3rem);line-height:1.06;letter-spacing:-.04em;
  color:var(--ink);
}
.pol-hero__p{
  margin:0;max-width:60ch;font-size:1.06rem;line-height:1.7;color:var(--ink-2);
}

/* the three documents, always one click apart */
.pol-switch{
  display:flex;flex-wrap:wrap;gap:.5rem;margin-top:clamp(1.4rem,2.6vw,2rem);
}
.pol-switch a{
  display:inline-flex;align-items:center;padding:.55rem 1.05rem;
  border:1px solid var(--line-3);border-radius:var(--r-pill);
  font-family:var(--f-head);font-weight:600;font-size:.9rem;letter-spacing:-.012em;
  color:var(--ink-2);text-decoration:none;background:var(--paper);
  transition:border-color .35s var(--e-out),color .35s var(--e-out),
             background .35s var(--e-out);
}
.pol-switch a:hover{border-color:var(--pc);color:var(--pc)}
.pol-switch a:focus-visible{outline:2px solid var(--pc);outline-offset:3px}
.pol-switch a[aria-current]{background:var(--pc);border-color:var(--pc);color:#fff}

/* 03 ── LAYOUT ────────────────────────────────────────────────────────── */

.pol-lay{
  display:grid;grid-template-columns:var(--pol-rail) minmax(0,1fr);
  gap:var(--pol-gap);align-items:start;
}

/* 04 ── CONTENTS RAIL ─────────────────────────────────────────────────── */

.pol-toc{
  position:sticky;top:calc(var(--hdr-h) + 1.6rem);
  max-height:calc(100vh - var(--hdr-h) - 3.2rem);
  overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;
  display:grid;gap:.7rem;align-content:start;
}
.pol-toc__t{
  font-family:var(--f-head);font-size:.64rem;letter-spacing:.18em;
  text-transform:uppercase;color:var(--ink-4);
}

/* find in this policy */
.pol-find{
  display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:.5rem;
  padding:.5rem .7rem;border:1px solid var(--line-3);border-radius:var(--r);
  background:var(--paper);color:var(--ink-4);
  transition:border-color .3s var(--e-out),color .3s var(--e-out);
}
.pol-find:focus-within{border-color:var(--pc);color:var(--pc)}
.pol-find svg{width:15px;height:15px;flex:none}
.pol-find input{
  border:0;background:none;padding:0;width:100%;
  font-family:var(--f-body);font-size:.88rem;color:var(--ink);
}
.pol-find input::placeholder{color:var(--ink-4)}
.pol-find input:focus{outline:none}
.pol-find input::-webkit-search-cancel-button{cursor:pointer}
.pol-find__n{
  font-family:var(--f-head);font-size:.68rem;letter-spacing:.06em;color:var(--ink-4);
  min-height:1em;
}

.pol-toc__l{margin:0;padding:0;list-style:none;border-left:1px solid var(--line)}
.pol-toc__l a{
  display:grid;grid-template-columns:1.9rem minmax(0,1fr);gap:.2rem;
  padding:.44rem 0 .44rem .9rem;
  font-size:.88rem;line-height:1.38;color:var(--ink-3);text-decoration:none;
  border-left:2px solid transparent;margin-left:-1px;
  transition:color .3s var(--e-out),border-color .3s var(--e-out);
}
.pol-toc__l a span{
  font-family:var(--f-head);font-size:.7rem;color:var(--ink-4);padding-top:.12rem;
}
.pol-toc__l a:hover{color:var(--ink)}
.pol-toc__l a:hover span{color:var(--ink-3)}
.pol-toc__l a[aria-current]{color:var(--pc);font-weight:600;border-left-color:var(--pc)}
.pol-toc__l a[aria-current] span{color:var(--pc)}
.pol-toc__l a:focus-visible{outline:2px solid var(--pc);outline-offset:-2px;border-radius:3px}
/* the find filter hides what does not match */
.pol-toc__l li[hidden]{display:none}

/* 05 ── THE DOCUMENT ──────────────────────────────────────────────────── */

.pol-doc{min-width:0}
.pol-lede{
  margin:0 0 var(--pol-sec);max-width:var(--pol-measure);
  font-size:1.16rem;line-height:1.7;color:var(--ink-2);
  padding-bottom:1.6rem;border-bottom:1px solid var(--line);
}
.pol-lede b{color:var(--ink);font-weight:600}

.pol-s{scroll-margin-top:calc(var(--hdr-h) + 1.4rem)}
.pol-s + .pol-s{margin-top:var(--pol-sec)}
.pol-s[hidden]{display:none}

.pol-s__h{
  margin:0 0 1rem;
  display:grid;grid-template-columns:auto minmax(0,1fr) auto;
  align-items:baseline;gap:.75rem;
  font-family:var(--f-head);font-weight:700;
  font-size:clamp(1.35rem,2.2vw,1.85rem);line-height:1.16;letter-spacing:-.032em;
  color:var(--ink);
  padding-bottom:.7rem;border-bottom:1px solid var(--line);
}
.pol-s__n{
  font-family:var(--f-head);font-size:.56em;font-weight:500;
  color:var(--pc);letter-spacing:.02em;
}
/* the anchor link: present on hover and to the keyboard, quiet otherwise */
.pol-s__a{
  display:grid;place-items:center;width:28px;height:28px;border-radius:50%;
  color:var(--ink-4);opacity:0;align-self:center;
  transition:opacity .3s var(--e-out),color .3s var(--e-out);
}
.pol-s__a svg{width:15px;height:15px}
.pol-s__h:hover .pol-s__a,
.pol-s__a:focus-visible{opacity:1}
.pol-s__a:hover{color:var(--pc)}
/* a policy whose contents list and headings carry no numbers */
.pol-toc--plain .pol-toc__l a{display:block}
.pol-doc--plain .pol-s__h{grid-template-columns:minmax(0,1fr) auto}
.pol-s__a:focus-visible{outline:2px solid var(--pc);outline-offset:2px}
.pol-s__a.is-copied{opacity:1;color:var(--pc)}

.pol-doc h3{
  margin:2rem 0 .6rem;font-family:var(--f-head);font-weight:700;
  font-size:1.1rem;line-height:1.3;letter-spacing:-.022em;color:var(--ink);
  max-width:var(--pol-measure);
}
.pol-doc p{
  margin:0 0 1.05rem;max-width:var(--pol-measure);
  font-size:1.04rem;line-height:1.76;color:var(--ink-2);
}
.pol-doc p:last-child{margin-bottom:0}
.pol-doc a{
  color:var(--pc);text-decoration:underline;text-underline-offset:.18em;
  text-decoration-thickness:1px;
  text-decoration-color:color-mix(in srgb,var(--pc) 40%,transparent);
}
.pol-doc a:hover{text-decoration-color:var(--pc)}

/* the find filter marks hits in the prose */
.pol-doc mark{
  background:color-mix(in srgb,var(--pc) 16%,transparent);
  color:inherit;border-radius:3px;padding:0 .12em;
}

/* 06 ── DEFINITIONS, NOTES, LISTS ─────────────────────────────────────── */

.pol-defs{
  margin:1.3rem 0;padding:0;max-width:var(--pol-measure);
  border-top:1px solid var(--line);
}
.pol-def{
  display:grid;grid-template-columns:minmax(0,10rem) minmax(0,1fr);gap:.2rem 1.4rem;
  padding:.85rem 0;border-bottom:1px solid var(--line);
}
.pol-def dt{
  font-family:var(--f-head);font-weight:600;font-size:.98rem;letter-spacing:-.016em;
  color:var(--ink);
}
.pol-def dd{margin:0;font-size:.98rem;line-height:1.7;color:var(--ink-2)}

.pol-note{
  margin:1.3rem 0;padding:1.1rem 1.3rem;max-width:var(--pol-measure);
  border-left:3px solid var(--pc);border-radius:0 var(--r) var(--r) 0;
  background:color-mix(in srgb,var(--pc) 4%,var(--paper-2));
}
.pol-note b{
  display:block;margin-bottom:.35rem;font-family:var(--f-head);font-weight:600;
  font-size:.86rem;letter-spacing:.02em;color:var(--ink);
}
.pol-note p{margin:0;font-size:.98rem;line-height:1.7}

.pol-ul{
  margin:1rem 0 1.2rem;padding:0;list-style:none;
  max-width:var(--pol-measure);display:grid;gap:.5rem;
}
.pol-ul li{
  position:relative;padding-left:1.4rem;
  font-size:1.02rem;line-height:1.7;color:var(--ink-2);
}
.pol-ul li::before{
  content:"";position:absolute;left:.25rem;top:.72em;
  width:5px;height:5px;border-radius:50%;background:var(--pc);opacity:.55;
}

/* 07 ── COOKIE CARDS ──────────────────────────────────────────────────── */

.pol-cookies{display:grid;gap:1rem;margin:1.4rem 0;max-width:var(--pol-measure)}
.pol-cookie{
  padding:1.2rem 1.35rem;border:1px solid var(--line);border-radius:var(--r-lg);
  background:var(--paper);
}
.pol-cookie__h{
  display:flex;flex-wrap:wrap;align-items:center;gap:.6rem;
  margin:0 0 .85rem;font-family:var(--f-head);font-weight:700;
  font-size:1.04rem;letter-spacing:-.02em;color:var(--ink);
}
.pol-tag{
  display:inline-flex;align-items:center;padding:.22rem .6rem;border-radius:var(--r-pill);
  background:color-mix(in srgb,var(--pc) 9%,#fff);color:var(--pc);
  font-family:var(--f-head);font-size:.62rem;letter-spacing:.1em;text-transform:uppercase;
  font-weight:500;
}
.pol-cookie__rows{margin:0;padding:0}
.pol-cookie__r{
  display:grid;grid-template-columns:minmax(0,8.5rem) minmax(0,1fr);gap:.2rem 1.2rem;
  padding:.6rem 0;
}
.pol-cookie__r + .pol-cookie__r{border-top:1px solid var(--line)}
.pol-cookie__r dt{
  font-family:var(--f-head);font-size:.64rem;letter-spacing:.14em;
  text-transform:uppercase;color:var(--ink-4);padding-top:.25rem;
}
.pol-cookie__r dd{margin:0;font-size:.96rem;line-height:1.68;color:var(--ink-2)}

.pol-browsers{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:.7rem;margin:1.3rem 0;max-width:var(--pol-measure);
}
.pol-browser{
  display:grid;gap:.15rem;padding:.85rem 1rem;
  border:1px solid var(--line);border-radius:var(--r);
  text-decoration:none !important;color:inherit;background:var(--paper);
  transition:border-color .35s var(--e-out),transform .35s var(--e-out);
}
.pol-browser:hover{border-color:var(--pc);transform:translateY(-2px)}
.pol-browser:focus-visible{outline:2px solid var(--pc);outline-offset:2px}
.pol-browser b{font-family:var(--f-head);font-weight:600;font-size:.96rem;color:var(--ink)}
.pol-browser span{font-size:.78rem;color:var(--ink-3);word-break:break-word}

/* 08 ── FIND STATE + FOOTER ───────────────────────────────────────────── */

/* shown by policy.js when the filter matches nothing */
.pol-empty{
  display:none;padding:2rem 1.4rem;max-width:var(--pol-measure);
  border:1px dashed var(--line-3);border-radius:var(--r-lg);
  text-align:center;background:var(--paper-2);
}
.pol-empty.is-on{display:grid;gap:.3rem}
.pol-empty b{font-family:var(--f-head);font-weight:700;font-size:1.02rem;color:var(--ink)}
.pol-empty span{font-size:.92rem;color:var(--ink-3)}

.pol-foot{
  display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;
  gap:1rem;margin-top:var(--pol-sec);padding-top:1.4rem;
  border-top:1px solid var(--line);
}
.pol-foot p{margin:0;font-size:.98rem;color:var(--ink-2);max-width:none}

/* 09 ── RESPONSIVE ────────────────────────────────────────────────────── */

@media (max-width:1100px){
  .pol{--pol-rail:210px}
}
@media (max-width:900px){
  .pol-lay{grid-template-columns:minmax(0,1fr);gap:2rem}
  .pol-toc{
    position:static;max-height:none;overflow:visible;
    padding-bottom:1.4rem;border-bottom:1px solid var(--line);
  }
  .pol-toc__l{
    display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));
    border-left:0;
  }
  .pol-toc__l a{padding-left:0;border-left:0;margin-left:0}
  .pol{--pol-measure:none}
  .pol-doc{width:min(100%,42em)}
}
@media (max-width:620px){
  .pol-def,.pol-cookie__r{grid-template-columns:minmax(0,1fr);gap:.15rem}
  .pol-def dt{font-size:.94rem}
  .pol-foot{flex-direction:column;align-items:flex-start}
  .pol-s__h{grid-template-columns:auto minmax(0,1fr);row-gap:.2rem}
  .pol-s__a{display:none}
  .pol-doc--plain .pol-s__h{grid-template-columns:minmax(0,1fr)}
}

@media (prefers-reduced-motion:reduce){
  .pol-switch a,.pol-browser,.pol-s__a{transition:none}
}
