/* site.css — the whole stylesheet for www.newhopelaw.com.
 *
 * Teal palette and the gear banner carry over from the original
 * clemcheng.com site. No JavaScript; everything here is plain CSS.
 * Icons are drawn with CSS masks at the end of the file.
 */

:root {
  --teal-950: #062a2e; --teal-900: #0a3a3f; --teal-800: #0d4e54; --teal-700: #0f646b;
  --teal-600: #00818b; --teal-500: #249fa3; --teal-300: #8fd0d1; --teal-100: #d5eded; --teal-50: #eef7f7;
  --gold: #c9a24a;
  --ink: #18282b; --muted: #546a6d; --rule: #dde7e7; --paper: #ffffff; --wash: #f4f8f8;
  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --sans: 'Source Sans 3', 'Segoe UI', Helvetica, Arial, sans-serif;
  --wrap: 74rem; --measure: 46rem; --radius: 10px;
  --shadow: 0 1px 2px rgba(6, 42, 46, .06), 0 8px 24px -12px rgba(6, 42, 46, .18);
  --shadow-lg: 0 2px 4px rgba(6, 42, 46, .06), 0 18px 40px -16px rgba(6, 42, 46, .28);
  --gears: url('/assets/img/brand/gears-wide.jpg');
}
:lang(zh-Hans) { --serif: 'Noto Serif SC', 'Songti SC', SimSun, serif; --sans: 'Source Sans 3', 'PingFang SC', 'Microsoft YaHei', 'Noto Sans SC', sans-serif; }
:lang(zh-Hant) { --serif: 'Noto Serif TC', 'Songti TC', PMingLiU, serif; --sans: 'Source Sans 3', 'PingFang TC', 'Microsoft JhengHei', 'Noto Sans TC', sans-serif; }
:lang(ja) { --serif: 'Noto Serif JP', 'Hiragino Mincho ProN', 'Yu Mincho', serif; --sans: 'Source Sans 3', 'Hiragino Sans', 'Yu Gothic UI', 'Meiryo', 'Noto Sans JP', sans-serif; }
[lang="en"] { --serif: 'Source Serif 4', Georgia, serif; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1.5rem; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--sans); font-size: 17.5px; line-height: 1.7; -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
:lang(zh), :lang(ja) { line-height: 1.85; }
img { max-width: 100%; height: auto; }
a { color: var(--teal-600); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, currentColor 45%, transparent); }
a:hover { color: var(--teal-800); text-decoration-color: currentColor; }
a:focus-visible, .btn:focus-visible, summary:focus-visible { outline: 3px solid var(--teal-500); outline-offset: 2px; border-radius: 3px; }
p { margin: 0 0 1.1em; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.22; color: var(--teal-900); margin: 1.8em 0 .55em; letter-spacing: -.005em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.2rem); margin-top: 0; letter-spacing: -.015em; }
h2 { font-size: clamp(1.5rem, 2.6vw, 1.95rem); }
h3 { font-size: 1.25rem; }
:lang(zh) h1, :lang(ja) h1 { letter-spacing: .02em; }
h1, h2, h3 { text-wrap: balance; }
.phrase { display: inline-block; }
:lang(ja) :is(h1, h2, h3, .hero-lede, .deck) { word-break: auto-phrase; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 28px; }
.wrap--narrow { max-width: calc(var(--measure) + 56px); }
.skip { position: absolute; left: -999px; top: 0; background: var(--teal-900); color: #fff; padding: 8px 14px; z-index: 20; }
.skip:focus { left: 8px; top: 8px; }
.kicker { font-family: var(--sans); font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--teal-600); margin: 0 0 .7rem; display: flex; align-items: center; gap: .6rem; }
.kicker::before { content: ""; width: 1.6rem; height: 2px; background: currentColor; opacity: .7; }
:lang(zh) .kicker, :lang(ja) .kicker { letter-spacing: .1em; font-size: .86rem; }
.lead { font-size: 1.16rem; color: var(--ink); }

/* ---------- top bar, masthead and nav ---------- */
.topbar { background: var(--teal-950); color: var(--teal-100); font-size: .84rem; }
.topbar-inner { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: .3rem 1.4rem; padding-top: .5rem; padding-bottom: .5rem; }
.topbar a { color: #e8f5f5; text-decoration: none; }
.topbar a:hover { color: #fff; text-decoration: underline; }
.topbar-contact { display: flex; flex-wrap: wrap; gap: .2rem 1.3rem; }
.langs { display: flex; flex-wrap: wrap; gap: .25rem; }
.langs a { padding: .1rem .6rem; border-radius: 999px; opacity: .85; }
.langs a:hover { opacity: 1; text-decoration: none; background: rgba(255,255,255,.1); }
.langs a[aria-current] { opacity: 1; background: var(--teal-600); color: #fff; font-weight: 600; }

.masthead { position: sticky; top: 0; z-index: 10; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--rule); }
.masthead-inner { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .6rem 2rem; padding-top: .85rem; padding-bottom: .85rem; }
.brand { display: flex; align-items: center; gap: .85rem; text-decoration: none; color: var(--teal-900); }
.brand:hover { color: var(--teal-900); }
.brand-mark { width: 46px; height: 46px; border-radius: 12px; flex: none; background: var(--teal-600) url('/assets/img/brand/gears.png') 30% 50% / auto 100% no-repeat; box-shadow: inset 0 0 0 1px rgba(255,255,255,.35), 0 4px 12px -4px rgba(0,129,139,.6); }
.brand-text { display: flex; flex-direction: column; line-height: 1.12; }
.brand-name { font-family: 'Source Serif 4', Georgia, serif; font-weight: 600; font-size: 1.42rem; letter-spacing: -.01em; }
.brand-tag { font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-top: 4px; }
:lang(zh) .brand-tag, :lang(ja) .brand-tag { letter-spacing: .12em; font-size: .8rem; }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: .2rem 1.6rem; }
.nav a { position: relative; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .97rem; padding: .35rem 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--teal-500); transform: scaleX(0); transform-origin: left; transition: transform .2s ease; }
.nav a:hover { color: var(--teal-700); }
.nav a:hover::after, .nav a[aria-current]::after { transform: scaleX(1); }
.nav a[aria-current] { color: var(--teal-700); }
.nav .nav-cta { color: #fff; background: var(--teal-600); padding: .45rem 1.05rem; border-radius: 999px; transition: background .2s; }
.nav .nav-cta::after { display: none; }
.nav .nav-cta:hover, .nav .nav-cta[aria-current] { color: #fff; background: var(--teal-800); }

/* ---------- gear banner: one image, scaled to fill, never tiled ---------- */
.hero, .page-hero { position: relative; color: #fff; background: var(--teal-800) var(--gears) center / cover no-repeat; isolation: isolate; }
.hero::before, .page-hero::before { content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(100deg, rgba(6, 42, 46, .93) 0%, rgba(7, 48, 53, .8) 34%, rgba(9, 62, 68, .38) 62%, rgba(12, 80, 86, .06) 100%); }
.hero::after, .page-hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: linear-gradient(90deg, var(--teal-500), var(--teal-300) 60%, transparent); }
.hero h1, .page-hero h1 { color: #fff; }
.hero .kicker, .page-hero .kicker { color: var(--teal-300); }

.hero { padding: clamp(4.5rem, 9vw, 7.5rem) 0 clamp(4rem, 8vw, 6.5rem); }
.hero h1 { max-width: 16em; font-size: clamp(2.3rem, 5.2vw, 3.7rem); }
.hero-lede { font-size: 1.22rem; max-width: 36em; color: #e2f2f2; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.hero a:not(.btn), .page-hero a { color: #fff; }

.page-hero { padding: clamp(2.8rem, 6vw, 4.2rem) 0 clamp(2.6rem, 5vw, 3.6rem); }
.page-hero h1 { margin: 0; max-width: 22em; }
.page-hero .deck { color: #dcefef; font-size: 1.15rem; max-width: 40em; margin: .9rem 0 0; }
.byline { margin: 1rem 0 0; color: var(--teal-100); font-size: .95rem; }

.stats { background: var(--teal-950); color: #cfe6e6; border-top: 1px solid rgba(255,255,255,.08); }
.stats-list { list-style: none; margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); }
.stats-list li { padding: 1.3rem 1.2rem 1.3rem 0; display: flex; flex-direction: column; gap: .1rem; border-right: 1px solid rgba(255,255,255,.1); padding-left: 1.2rem; }
.stats-list li:first-child { padding-left: 0; }
.stats-list li:last-child { border-right: 0; }
.stats strong { font-family: var(--serif); font-size: 1.3rem; color: #fff; font-weight: 600; }
.stats span { font-size: .9rem; color: #a9cccc; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: .5rem; padding: .75rem 1.4rem; border-radius: 999px; background: var(--teal-600); color: #fff; font-weight: 700; font-size: .98rem; text-decoration: none; line-height: 1.3; border: 2px solid var(--teal-600); transition: background .2s, border-color .2s, color .2s, transform .2s; }
.btn:hover { background: var(--teal-800); border-color: var(--teal-800); color: #fff; transform: translateY(-1px); }
.btn--light { background: #fff; color: var(--teal-900); border-color: #fff; }
.btn--light:hover { background: var(--teal-50); border-color: var(--teal-50); color: var(--teal-900); }
.btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.btn--ghost:hover { background: rgba(255,255,255,.12); border-color: #fff; }
.btn--outline { background: transparent; color: var(--teal-700); border-color: var(--teal-500); }
.btn--outline:hover { background: var(--teal-50); color: var(--teal-800); border-color: var(--teal-600); }

/* ---------- sections ---------- */
.page-body { padding-top: 3.2rem; padding-bottom: 4rem; }
.page-body > :first-child { margin-top: 0; }
.section { padding: clamp(3.5rem, 7vw, 5.5rem) 0; }
.section--wash { background: var(--wash); }
.section-head { max-width: 42em; margin-bottom: 2.4rem; }
.section-head h2 { margin-top: 0; }
.section-head p:last-child { color: var(--muted); font-size: 1.1rem; margin-bottom: 0; }
.section-head--row { max-width: none; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1rem; }
.section-head--row h2 { margin-bottom: 0; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1.3rem; }
.card { position: relative; display: flex; flex-direction: column; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.6rem 1.6rem 1.4rem; color: var(--ink); text-decoration: none; box-shadow: var(--shadow); transition: transform .2s ease, box-shadow .2s ease, border-color .2s; }
a.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--teal-100); color: var(--ink); }
.card h2, .card h3 { margin: 0 0 .45rem; font-size: 1.22rem; }
.card p { color: var(--muted); margin: 0 0 1rem; font-size: .98rem; }
.card-link { margin-top: auto; font-weight: 700; color: var(--teal-600); font-size: .95rem; }
.card-link::after { content: " →"; transition: margin .2s; }
a.card:hover .card-link::after { margin-left: .25rem; }
.card-icon { display: block; width: 46px; height: 46px; border-radius: 12px; background: var(--teal-50); margin-bottom: 1.1rem; position: relative; }
.card-icon::before { content: ""; position: absolute; inset: 11px; background: var(--teal-600); -webkit-mask: var(--icon) center / contain no-repeat; mask: var(--icon) center / contain no-repeat; }

.profile { display: grid; grid-template-columns: minmax(0, 20rem) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.profile h2 { margin-top: 0; }
.profile-photo { margin: 0; }
.profile-photo img { display: block; width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.profile-photo figcaption { font-size: .88rem; color: var(--muted); margin-top: .8rem; line-height: 1.5; }
.profile--about { margin-bottom: 1rem; }
.profile--about h2 { margin: 1.6rem 0 0; }
.subtitle { color: var(--muted); margin: 0 0 1rem; }
.facts { list-style: none; margin: 1.2rem 0 1.6rem; padding: 0; border-top: 1px solid var(--rule); }
.facts li { padding: .75rem 0; border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: 9rem 1fr; gap: 1rem; font-size: .98rem; }
.facts strong { color: var(--teal-900); }

.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; counter-reset: pillar; }
.pillars > div { border-top: 2px solid var(--teal-500); padding-top: 1.3rem; counter-increment: pillar; }
.pillars > div::before { content: "0" counter(pillar); font-family: 'Source Serif 4', Georgia, serif; color: var(--teal-500); font-size: .95rem; font-weight: 600; letter-spacing: .1em; }
.pillars h3 { margin: .4rem 0 .5rem; }
.pillars p { color: var(--muted); margin: 0; }

.video { max-width: 52rem; }
.video-frame { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-lg); background: var(--teal-950); }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.cta-band { position: relative; background: var(--teal-900) var(--gears) center / cover no-repeat; color: #e2f2f2; padding: 3.6rem 0; isolation: isolate; }
.cta-band::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(6,42,46,.95), rgba(8,52,57,.85) 50%, rgba(12,74,80,.45)); }
.cta-band h2 { color: #fff; margin: 0 0 .4rem; }
.cta-band .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1.5rem; }
.cta-band p { margin: 0; max-width: 40em; }
.cta-band a:not(.btn) { color: #fff; }

.callout { background: var(--teal-50); border: 1px solid var(--teal-100); border-left: 4px solid var(--teal-500); border-radius: var(--radius); padding: 1.4rem 1.6rem; margin: 2rem 0; }
.callout > :last-child { margin-bottom: 0; }
.callout h2, .callout h3 { margin-top: 0; }
.callout h2 { font-size: 1.3rem; }

/* ---------- inner pages ---------- */
.prose { max-width: var(--measure); }
.prose--wide { max-width: 52rem; }
.prose > :first-child { margin-top: 0; }
.with-aside { display: grid; grid-template-columns: 13rem minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
.toc { position: sticky; top: 6.5rem; display: flex; flex-direction: column; border-left: 2px solid var(--rule); font-size: .95rem; }
.toc a { color: var(--muted); text-decoration: none; padding: .35rem 0 .35rem 1rem; margin-left: -2px; border-left: 2px solid transparent; }
.toc a:hover { color: var(--teal-700); border-left-color: var(--teal-500); }
.practice { padding-top: .4rem; }
.practice + .practice { border-top: 1px solid var(--rule); margin-top: 2.4rem; }
.practice h2 { margin-top: 1.6rem; }
.checklist { list-style: none; padding: 0; margin: 0 0 1.2em; }
.checklist li { position: relative; padding-left: 1.9rem; margin-bottom: .55rem; }
.checklist li::before { content: ""; position: absolute; left: 0; top: .42em; width: 1.05rem; height: 1.05rem; border-radius: 50%; background: var(--teal-50); box-shadow: inset 0 0 0 1px var(--teal-100); }
.checklist li::after { content: ""; position: absolute; left: .36rem; top: .62em; width: .32rem; height: .55rem; border: solid var(--teal-600); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.figure-row { display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: flex-end; margin: 1.5rem 0; }
.figure { margin: 0; flex: 1 1 18rem; }
.figure img { display: block; border-radius: var(--radius); box-shadow: var(--shadow); }
.figure figcaption { font-size: .9rem; color: var(--muted); margin-top: .6rem; }
.figure--badge { flex: 0 0 auto; }
.figure--badge img { box-shadow: none; }

.steps { list-style: none; padding: 0; margin: 0 0 3rem; counter-reset: step; display: grid; gap: 1.2rem; }
.steps li { counter-increment: step; position: relative; padding: 1.5rem 1.6rem 1.3rem 5rem; border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow); background: var(--paper); }
.steps li::before { content: counter(step); position: absolute; left: 1.5rem; top: 1.45rem; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--teal-600); color: #fff; font-family: 'Source Serif 4', Georgia, serif; font-weight: 600; font-size: 1.15rem; display: grid; place-items: center; }
.steps h2 { margin: 0 0 .4rem; font-size: 1.3rem; }
.steps p { margin: 0; color: var(--muted); }
.quote-cta { font-family: var(--serif); font-size: 1.35rem; font-weight: 600; color: var(--teal-900); background: var(--teal-50); border-left: 4px solid var(--teal-500); border-radius: var(--radius); padding: 1.2rem 1.5rem; margin: 0 0 2.2rem; }
.drawing-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 1.2rem; margin: 1.5rem 0 1rem; }
.drawing-card { margin: 0; border: 1px solid var(--rule); border-radius: var(--radius); overflow: hidden; background: var(--paper); box-shadow: var(--shadow); }
.drawing-card img { display: block; width: 100%; height: auto; background: var(--wash); padding: 1rem 1.5rem; border-bottom: 1px solid var(--rule); }
.drawing-card figcaption { padding: 1rem 1.2rem 1.1rem; }
.drawing-card h3 { margin: 0 0 .5rem; font-size: 1.12rem; }
.drawing-card ul { margin: 0; padding-left: 1.1em; color: var(--muted); font-size: .94rem; }
.drawing-card li { margin-bottom: .3rem; }
.figure--wide img { width: 100%; max-width: 560px; background: var(--wash); padding: 1rem; box-shadow: none; border: 1px solid var(--rule); }
.panel { background: var(--wash); border-radius: var(--radius); padding: 1.8rem 2rem; margin: 0 0 3rem; }
.panel h2 { margin-top: 0; }
.numbered { padding-left: 1.4em; margin: 0 0 1.5rem; }
.numbered > li { margin-bottom: .55rem; padding-left: .3em; }
.numbered > li::marker { color: var(--teal-600); font-weight: 700; }
.numbered ol { margin: .4rem 0; }
.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { cursor: pointer; list-style: none; padding: 1.05rem 2.5rem 1.05rem 0; font-family: var(--serif); font-weight: 600; font-size: 1.12rem; color: var(--teal-900); position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: .3rem; top: .8rem; font-family: var(--sans); font-weight: 400; font-size: 1.6rem; line-height: 1; color: var(--teal-600); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--teal-600); }
.faq details > :not(summary) { margin: 0 0 1.1rem; color: var(--ink); }

.cases { list-style: none; padding: 0; margin: 0 0 1.2em; }
.cases li { padding: .9rem 1.2rem; border-left: 3px solid var(--teal-500); background: var(--wash); border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: .7rem; }
.two-col { columns: 2 18rem; column-gap: 2.5rem; padding-left: 1.1em; }
.two-col li { break-inside: avoid; margin-bottom: .2rem; }
.two-col li::marker { color: var(--teal-500); }
.tags { list-style: none; padding: 0; margin: 0 0 1.2em; display: flex; flex-wrap: wrap; gap: .5rem; }
.tags li { background: var(--teal-50); color: var(--teal-800); border: 1px solid var(--teal-100); padding: .3rem .85rem; border-radius: 999px; font-size: .94rem; }

.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1.3rem; margin: 0 0 2.5rem; }
.contact-grid .card p { color: var(--ink); margin-bottom: .4rem; }
.contact-grid .card h2 { font-family: var(--sans); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.contact-big { margin: .3rem 0 .6rem !important; }
.contact-img { display: inline-block; vertical-align: middle; max-width: 100%; height: auto; }
.contact-img--small { vertical-align: -6px; }
.notice { background: var(--wash); border: 1px solid var(--rule); border-radius: var(--radius); padding: .8rem 1.1rem; color: var(--muted); font-size: .95rem; margin: 0 0 1.8rem; }
.contact-split { display: grid; grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr)); gap: 1.5rem; align-items: start; }
.contact-split .callout { margin: 0; }
.wechat { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .9rem; border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.4rem 1.5rem 1.6rem; }
.wechat h2 { margin: 0; font-size: 1.35rem; }
.wechat h2 strong { color: var(--teal-600); font-family: var(--sans); letter-spacing: .02em; }
.qr { width: 300px; max-width: 100%; height: auto; border-radius: 8px; }
.lang-list { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 1rem; }

/* ---------- article body: HTML carried over from the blog ---------- */
.post-body { overflow-wrap: break-word; font-size: 1.04rem; }
.post-body > :first-child { margin-top: 0; }
.post-body h2 { font-size: 1.55rem; }
.post-body h3 { font-size: 1.25rem; }
.post-body h4 { font-size: 1.05rem; }
.post-body img { display: block; max-width: 100%; height: auto; margin: 1.8rem auto; border-radius: var(--radius); box-shadow: var(--shadow); }
.post-body ul, .post-body ol { margin: 0 0 1.1em; padding-left: 1.5em; }
.post-body li { margin-bottom: .35em; }
.post-body li::marker { color: var(--teal-600); }
.post-body blockquote { margin: 0 0 1.5em; padding: .6em 0 .6em 1.3em; border-left: 3px solid var(--teal-500); color: var(--muted); font-style: italic; }
.post-body table { border-collapse: collapse; width: 100%; margin: 0 0 1.5em; display: block; overflow-x: auto; }
.post-body th, .post-body td { padding: .5em .8em; text-align: left; border: 1px solid var(--rule); vertical-align: top; }
.post-body th { background: var(--wash); }
.post-body hr { border: 0; border-top: 1px solid var(--rule); margin: 2em 0; }
.dated-note { background: #fbf7ec; border: 1px solid #efe3c2; border-left: 4px solid var(--gold); border-radius: var(--radius); padding: .85rem 1.1rem; font-size: .93rem; color: #5b4a1e; margin: 0 0 2.2rem; }
.dated-note a { color: #7a5c12; }
.source-note { font-size: .92rem; color: var(--muted); border-top: 1px solid var(--rule); margin-top: 2.8rem; padding-top: 1.2rem; }
.source-note a { overflow-wrap: anywhere; }
.page-nav { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }

/* ---------- article lists ---------- */
.post-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); gap: 1.3rem; }
.post-card { position: relative; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.5rem 1.6rem; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; }
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.post-card .post-item__title a::after { content: ""; position: absolute; inset: 0; }
.year-group { margin-top: 2.8rem; }
.year-group:first-child { margin-top: 0; }
.year-group > h2 { margin: 0 0 .3rem; font-family: 'Source Serif 4', Georgia, serif; font-size: 1.05rem; letter-spacing: .14em; color: var(--teal-600); padding-bottom: .6rem; border-bottom: 1px solid var(--rule); }
.post-list { list-style: none; margin: 0; padding: 0; }
.post-item { padding: 1.3rem 0; border-bottom: 1px solid var(--rule); }
.post-item:last-child { border-bottom: 0; }
.post-item__title { font-size: 1.24rem; margin: 0 0 .35rem; }
.post-item__title a { color: var(--teal-900); text-decoration: none; }
.post-item__title a:hover { color: var(--teal-600); text-decoration: underline; }
.post-item__meta { font-size: .8rem; color: var(--muted); margin: 0 0 .35rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.post-item__excerpt { margin: 0; color: var(--muted); font-size: .98rem; }

/* ---------- article filter (CSS only, uses :has) ---------- */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 2rem; }
.filters input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.filters label { cursor: pointer; padding: .4rem 1rem; border: 1px solid var(--teal-100); border-radius: 999px; background: var(--paper); color: var(--teal-800); font-weight: 600; font-size: .92rem; transition: background .15s, color .15s, border-color .15s; }
.filters label:hover { border-color: var(--teal-500); }
.filters input:checked + label { background: var(--teal-600); border-color: var(--teal-600); color: #fff; }
.filters input:focus-visible + label { outline: 3px solid var(--teal-500); outline-offset: 2px; }
.tag { display: inline-block; margin-left: .6rem; padding: .05rem .55rem; border-radius: 999px; background: var(--teal-50); color: var(--teal-700); font-size: .72rem; letter-spacing: .06em; vertical-align: 1px; }
.filterable:has(#tag-ip:checked) .post-item:not([data-tags~="ip"]), .filterable:has(#tag-ip:checked) .year-group:not(:has([data-tags~="ip"])) { display: none; }
.filterable:has(#tag-patent:checked) .post-item:not([data-tags~="patent"]), .filterable:has(#tag-patent:checked) .year-group:not(:has([data-tags~="patent"])) { display: none; }
.filterable:has(#tag-trademark:checked) .post-item:not([data-tags~="trademark"]), .filterable:has(#tag-trademark:checked) .year-group:not(:has([data-tags~="trademark"])) { display: none; }
.filterable:has(#tag-copyright:checked) .post-item:not([data-tags~="copyright"]), .filterable:has(#tag-copyright:checked) .year-group:not(:has([data-tags~="copyright"])) { display: none; }

/* ---------- footer ---------- */
.site-footer { background: var(--teal-950); color: #b9d6d6; font-size: .95rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1.2fr; gap: 2rem; padding-top: 3rem; padding-bottom: 2.2rem; }
.footer-grid h2 { font-family: var(--sans); font-size: .76rem; letter-spacing: .16em; text-transform: uppercase; color: var(--teal-300); margin: 0 0 .8rem; }
.footer-grid p { margin: 0 0 .6rem; }
.footer-brand { font-family: 'Source Serif 4', Georgia, serif; font-size: 1.4rem; color: #fff; }
.footer-legal { padding-top: 1.6rem; padding-bottom: 2.2rem; font-size: .84rem; color: #8fb2b2; }
.footer-legal p { margin: 0 0 .5rem; max-width: 62em; }

@media (max-width: 960px) {
  .with-aside { grid-template-columns: 1fr; }
  .toc { position: static; flex-direction: row; flex-wrap: wrap; border-left: 0; gap: .4rem; }
  .toc a { border: 1px solid var(--rule); border-radius: 999px; padding: .25rem .8rem; margin: 0; }
  .toc a:hover { border-color: var(--teal-500); }
  .stats-list { grid-template-columns: repeat(2, 1fr); }
  .stats-list li { border-right: 0; padding-left: 0; }
  .pillars { grid-template-columns: 1fr; gap: 1.6rem; }
}
@media (max-width: 860px) {
  .profile { grid-template-columns: 1fr; }
  .profile-photo { max-width: 18rem; }
  .masthead { position: static; }
  .masthead-inner { flex-direction: column; align-items: flex-start; }
  .nav { width: 100%; gap: .3rem 1.2rem; }
  .nav a { white-space: nowrap; font-size: .94rem; }
  .nav .nav-cta { padding: .3rem .9rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  body { font-size: 16.5px; }
  .wrap { padding: 0 16px; }
  .topbar-inner { justify-content: center; }
  .topbar-contact { display: none; }
  .langs { gap: 0; flex-wrap: nowrap; }
  .langs a { padding: .1rem .45rem; font-size: .78rem; white-space: nowrap; }
  .hero-lede { font-size: 1.08rem; }
  .facts li { grid-template-columns: 1fr; gap: .1rem; }
  .brand-name { font-size: 1.25rem; }
  .steps li { padding: 4.2rem 1.2rem 1.2rem; }
  .steps li::before { top: 1.2rem; left: 1.2rem; }
  .panel { padding: 1.4rem 1.2rem; }
  .footer-grid { grid-template-columns: 1fr; }
  .stats strong { font-size: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
@media print {
  .topbar, .nav, .cta-band, .toc, .site-footer .footer-grid { display: none; }
  .masthead { position: static; }
  .page-hero, .hero { background: none; color: var(--ink); }
  .page-hero::before, .hero::before { display: none; }
  .page-hero h1, .hero h1 { color: var(--ink); }
}

/* ---------- icons (CSS masks) ---------- */
.card-icon--patent { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 22h4M12 2a7 7 0 0 0-4 12.7V17h8v-2.3A7 7 0 0 0 12 2z'/%3E%3C/svg%3E"); }
.card-icon--trademark { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20.59 13.41l-7.17 7.17a2 2 0 0 1-2.83 0L2 12V2h10l8.59 8.59a2 2 0 0 1 0 2.82z'/%3E%3Cpath d='M7 7h.01'/%3E%3C/svg%3E"); }
.card-icon--copyright { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M15 9.35a4 4 0 1 0 0 5.3'/%3E%3C/svg%3E"); }
.card-icon--litigation { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3v18M7 21h10M4 7h16M5 7l-3 7a3 3 0 0 0 6 0zM19 7l-3 7a3 3 0 0 0 6 0z'/%3E%3C/svg%3E"); }
.card-icon--business { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='7' width='20' height='14' rx='2'/%3E%3Cpath d='M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16'/%3E%3C/svg%3E"); }
.card-icon--domain { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M2 12h20M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z'/%3E%3C/svg%3E"); }
.card-icon--phone { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.36 1.9.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.91.34 1.85.57 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E"); }
.card-icon--email { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='4' width='20' height='16' rx='2'/%3E%3Cpath d='m22 6-10 7L2 6'/%3E%3C/svg%3E"); }
.card-icon--office { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13S3 17 3 10a9 9 0 0 1 18 0z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E"); }
