/* The legal documents (A2, 2026-11; slice S13a): the board Legal (.scratch/ui_wave1/project/Legal.dc.html,
   LGL-1…7). A long text on plain paper: one reading column of 720px and, at its left, a rail that
   stays in view (the kicker, the title, the effective date and version, the other document as a
   word, the find line, the sections as beads on one thread: blue = being read, filled = read past,
   gold = holds what was searched). The text is counsel's (templates/legal/documents/*_body.html):
   this file styles its plain elements (p, ul/li, h2, h3, strong, a, table) inside .lg-col and never
   changes a word. Board-local classes carry the lg- prefix. Behaviour: static/js/a2/legal.js. Flat. */

.lg{--c:21,23,30;display:grid;grid-template-columns:330px minmax(0,720px);column-gap:76px;align-items:start;padding-bottom:120px;color:var(--ink)}

/* the top of the page fades under the brand row, so a line is never cut by the page's edge (the legal
   page keeps its own band: on a phone it is solid, under the sticky find bar; the shell's band,
   templates/a2/chrome.html .a2-band, leaves this page out. FX-A 2026-11) */
.lg::before{content:"";position:fixed;left:0;right:0;top:0;z-index:20;height:76px;background:linear-gradient(#F4EFE6 62%,rgba(244,239,230,0));pointer-events:none}

/* -- the rail -------------------------------------------------------------------------------------- */

.lg-rl{position:sticky;top:92px;display:flex;flex-direction:column;max-height:calc(100vh - 116px);max-height:calc(100dvh - 116px);overflow:auto;scrollbar-width:thin}
.lg-k{margin:0;font:700 12px/1 var(--fd);letter-spacing:.18em;text-transform:uppercase;color:var(--faint)}
.lg-rl h1{margin:10px 0 0;font:800 44px/1.02 var(--fd);letter-spacing:-.02em;text-wrap:balance}
.lg-dt{margin:10px 0 0;font:600 15px/1.35 var(--fb);color:var(--mut)}
.lg-sb{align-self:flex-start;margin-top:4px}
.lg-toc{display:flex;flex-direction:column;min-height:0}
.lg-fd{position:relative;flex:none;margin-top:14px}
.lg-fd[hidden]{display:none}
.lg-fd svg{position:absolute;left:0;top:14px;width:19px;height:19px;color:var(--mut);pointer-events:none}
.lg-fd .fin{padding-left:28px;font-size:19px;font-weight:700;-webkit-appearance:none;appearance:none}
.lg-fd .fin::-webkit-search-cancel-button{-webkit-appearance:none;appearance:none}
.lg-fd small{display:block;min-height:18px;margin-top:6px;font:600 13px/1.3 var(--fb);color:var(--goldD)}
.lg-tc{position:relative;flex:none;margin-top:8px;padding:0 0 8px 2px}
.lg-tc::before{content:"";position:absolute;left:12px;top:8px;bottom:16px;width:2px;border-radius:1px;background:var(--line2)}
.lg-ti{position:relative;display:flex;align-items:center;gap:12px;width:100%;min-height:25px;color:var(--mut);font:600 14.5px/1.15 var(--fb);text-decoration:none;white-space:nowrap;transition:color .2s}
.lg-ti i{position:relative;flex:none;display:grid;place-items:center;width:22px;height:22px}
.lg-ti i::after{content:"";width:9px;height:9px;border-radius:50%;background:#F4EFE6;box-shadow:inset 0 0 0 2px var(--line2);transition:width .3s cubic-bezier(.3,1.6,.5,1),height .3s cubic-bezier(.3,1.6,.5,1),background .2s,box-shadow .2s,transform .2s}
.lg-ti span{overflow:hidden;text-overflow:ellipsis}
.lg-ti:hover{color:var(--ink)}
.lg-ti:hover i::after{transform:scale(1.25)}
.lg-ti.lg-past i::after{background:var(--ink);box-shadow:none}
.lg-ti.lg-cur{color:var(--ink);font-weight:800}
.lg-ti.lg-cur i::after{width:16px;height:16px;background:var(--blue);box-shadow:0 0 0 5px rgba(28,57,187,.16)}
.lg-ti.lg-hit{color:var(--goldD)}
.lg-ti.lg-hit i::after{background:#E8A21A;box-shadow:0 0 0 4px rgba(232,162,26,.22)}
.lg-ti.lg-hit.lg-cur i::after{background:var(--blue)}
.lg-bar{display:none}
.lg-bar[hidden]{display:none}

/* -- the reading column: counsel's text, word for word ---------------------------------------------- */

.lg-col{min-width:0;padding-top:4px}
.lg-col > p{margin:14px 0 0;font:500 18px/1.62 var(--fb);color:rgba(21,23,30,.86)}
.lg-col > p:first-child{margin-top:0}
.lg-col ul{margin:6px 0 0;padding:0;list-style:none}
.lg-col li{position:relative;margin:10px 0 0;padding-left:24px;font:500 17px/1.6 var(--fb);color:rgba(21,23,30,.86)}
.lg-col li::before{content:"";position:absolute;left:4px;top:11px;width:6px;height:6px;border-radius:50%;background:var(--ink)}
.lg-col h2{margin:52px 0 0;font:800 28px/1.15 var(--fd);letter-spacing:-.01em;scroll-margin-top:96px;border-radius:6px}
.lg-col h3{margin:30px 0 0;font:800 21px/1.2 var(--fd);scroll-margin-top:96px}
.lg-col h2 + p,.lg-col h3 + p{margin-top:12px}
.lg-col strong,.lg-col b{color:var(--ink);font-weight:700}
.lg-col a{color:var(--ink);font-weight:700;text-decoration:none;box-shadow:inset 0 -1.5px 0 rgba(21,23,30,.3);transition:box-shadow .2s}
.lg-col a:hover{box-shadow:inset 0 -2px 0 var(--ink)}
/* a deep link (#deleting-your-account, #energy) opens with a brief gold wash on its heading */
.lg-col h2:target,.lg-col h3:target{animation:lg-wash 2.4s ease-out both}
@keyframes lg-wash{0%,35%{background:var(--goldT);box-shadow:0 0 0 8px var(--goldT)}100%{background:transparent;box-shadow:0 0 0 8px transparent}}
/* the tables (the two registry tables and the legal-bases table of section 3): hairline rows,
   small-caps headers, every column kept */
.lg-col table{width:100%;margin:16px 0 0;border-collapse:collapse;font:500 14.5px/1.45 var(--fb);color:rgba(21,23,30,.84)}
.lg-col thead th{padding:6px 14px 6px 0;text-align:left;vertical-align:bottom;font:700 11.5px/1.25 var(--fd);letter-spacing:.12em;text-transform:uppercase;color:var(--faint)}
.lg-col tbody tr{border-top:1.5px solid var(--line)}
.lg-col tbody th,.lg-col tbody td{padding:11px 14px 11px 0;text-align:left;vertical-align:top;font-size:14.5px}
.lg-col tbody th,.lg-col tbody td:first-child{font-weight:700;color:var(--ink)}
.lg-col tbody a{color:var(--blue);box-shadow:none}
.lg-col tbody a:hover{box-shadow:inset 0 -1.5px 0 var(--blue)}
.lg-tbl.lg-c5 thead th:nth-child(1){width:150px}
.lg-tbl.lg-c5 thead th:nth-child(4){width:96px}
.lg-tbl.lg-c5 thead th:nth-child(5){width:62px}
.lg-tw{margin-top:4px}
/* what was searched: its paragraphs take a light gold wash, its rows a gold edge */
.lg-col > p.lg-hit,.lg-col li.lg-hit{margin-left:-12px;padding-left:12px;border-radius:8px;background:linear-gradient(90deg,rgba(232,162,26,.2),rgba(232,162,26,0) 80%)}
.lg-col li.lg-hit{padding-left:36px}
.lg-col li.lg-hit::before{left:16px}
.lg-col h3.lg-hit{color:var(--goldD)}
.lg-col tr.lg-hit{box-shadow:inset 3px 0 0 #E8A21A}
.lg-col tr.lg-hit > :first-child{padding-left:10px}
.lg-col > p.lg-end{margin:56px 0 0;padding-top:18px;border-top:1.5px solid var(--line);font:600 16px/1.5 var(--fb);color:var(--mut)}
.lg-col > p.lg-end:has(> a){display:block}
.lg-col > p.lg-end:not(:has(> a)){display:none}

/* -- in between (700–1100px): the rail narrower ----------------------------------------------------- */

@media (max-width:1099px) and (min-width:700px) and (orientation:landscape){
  .lg{grid-template-columns:260px minmax(0,1fr);column-gap:44px}
  .lg-rl h1{font-size:36px}
}

/* -- below 700px: the rail folds into a bar under the title; the contents are a bottom sheet -------- */

@media (max-width:699px),(orientation:portrait) and (max-width:1199px){
  .lg{display:block;padding-bottom:96px}
  .lg::before{height:80px;background:#F4EFE6}
  .lg-rl{display:contents}
  .lg-rl h1{font-size:38px}
  .lg-bar:not([hidden]){position:sticky;top:64px;z-index:30;display:flex;align-items:center;gap:10px;width:calc(100% + 32px);min-height:48px;margin:14px -16px 0;padding:0 16px;border:0;background:rgba(244,239,230,.97);box-shadow:0 1px 0 var(--line);font:700 15px/1.2 var(--fb);color:var(--ink);text-align:left}
  .lg-bar i{flex:none;width:12px;height:12px;border-radius:50%;background:var(--blue);box-shadow:0 0 0 4px rgba(28,57,187,.16)}
  .lg-bar span{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .lg-bar small{flex:none;font:700 13px/1 var(--fb);color:var(--faint)}
  .lg-toc{margin-top:18px}
  .lg-js .lg-toc{position:fixed;left:8px;right:8px;bottom:8px;z-index:85;display:none;max-height:calc(100dvh - 120px);margin:0;padding:18px 20px 12px;overflow:auto;border-radius:22px;background:#fff;box-shadow:0 30px 60px -28px rgba(10,14,40,.5),0 2px 0 rgba(21,23,30,.04)}
  .lg-js.lg-open .lg-toc{display:flex;animation:a2-pop .28s cubic-bezier(.3,1.4,.5,1) both;transform-origin:50% 100%}
  .lg-js .lg-fd{margin-top:0}
  .lg-ti{min-height:40px;white-space:normal}
  .lg-ti span{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
  .lg-col{margin-top:22px}
  .lg-col > p{font-size:17px}
  .lg-col li{font-size:16px}
  .lg-col h2{margin-top:40px;font-size:24px;scroll-margin-top:124px}
  .lg-col h3{font-size:19px;scroll-margin-top:124px}
  /* a table: one block per row, its first cell the heading, the others "label: value" lines */
  .lg-col table,.lg-col tbody,.lg-col tr,.lg-col tbody th,.lg-col tbody td{display:block;width:auto}
  .lg-col thead{display:none}
  .lg-col tbody tr{padding:12px 0}
  .lg-col tbody th,.lg-col tbody td{padding:2px 0}
  .lg-col tbody th,.lg-col tbody td:first-child{font-size:15.5px}
  .lg-col tbody td[data-th]::before{content:attr(data-th) ": ";font:700 11px/1.6 var(--fd);letter-spacing:.1em;text-transform:uppercase;color:var(--faint)}
  .lg-col td:empty{display:none}
}

@media (prefers-reduced-motion:no-preference){
  html:has(.lg){scroll-behavior:smooth}
}
@media (prefers-reduced-motion:reduce){
  .lg-col h2:target,.lg-col h3:target{animation:none;background:var(--goldT)}
  .lg-js.lg-open .lg-toc{animation:none}
}
