/* ==========================================================
   IP Ahead — Intellectual Property Attorneys
   Theme: brand orange + deep navy (from logo), Lusitana / Lato
   ========================================================== */

:root {
  --orange: #d2691e;
  --orange-bright: #e8821e;
  --orange-dark: #a9531a;
  --orange-tint: #fbf1e8;
  --navy: #14212e;
  --navy-2: #1d2f40;
  --navy-3: #2a4155;
  --ink: #1b1b1b;
  --text: #4a4f55;
  --muted: #7b8188;
  --line: #e7e2dc;
  --bg: #ffffff;
  --bg-soft: #faf7f3;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(20, 33, 46, .04), 0 8px 24px rgba(20, 33, 46, .06);
  --shadow-lg: 0 2px 4px rgba(20, 33, 46, .04), 0 24px 48px rgba(20, 33, 46, .12);
  --serif: 'Lusitana', Georgia, serif;
  --sans: 'Lato', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --container: 1180px;
  --header-h: 78px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--orange); text-decoration: none; transition: color .2s; }
a:hover { color: var(--orange-dark); }
h1, h2, h3, h4 {
  font-family: var(--serif);
  color: var(--ink);
  line-height: 1.2;
  margin: 0 0 .5em;
  font-weight: 700;
  text-wrap: balance;
}
p { margin: 0 0 1.1em; text-wrap: pretty; }
strong { color: var(--ink); }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.section { padding: 104px 0; }
.section--soft { background: var(--bg-soft); }
.section--navy { background: var(--navy); color: #c7d0d9; }
.section--navy h2, .section--navy h3 { color: #fff; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--sans);
  font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--orange); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.section-head { max-width: 720px; margin-bottom: 56px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .eyebrow::after { content: ""; width: 28px; height: 2px; background: currentColor; }
.section-head h2 { font-size: clamp(30px, 4vw, 44px); }
.section-head p { font-size: 18px; color: var(--muted); margin: 0; }
.section--navy .section-head p { color: #9fb0c0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 28px; border-radius: 999px;
  font-family: var(--sans); font-weight: 700; font-size: 15px; letter-spacing: .02em;
  border: 2px solid transparent; cursor: pointer;
  transition: background .2s, color .2s, border-color .2s, transform .2s, box-shadow .2s;
}
.btn svg { width: 18px; height: 18px; transition: transform .2s; }
.btn:hover svg { transform: translateX(3px); }
.btn--primary { background: var(--orange); color: #fff; box-shadow: 0 8px 20px rgba(210, 105, 30, .28); }
.btn--primary:hover { background: var(--orange-bright); color: #fff; transform: translateY(-1px); }
.btn--ghost { border-color: rgba(255, 255, 255, .35); color: #fff; }
.btn--ghost:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, .06); }
.btn--outline { border-color: var(--navy); color: var(--navy); }
.btn--outline:hover { background: var(--navy); color: #fff; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.scrolled { border-color: var(--line); box-shadow: 0 4px 20px rgba(20, 33, 46, .05); }
.site-header .container { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  position: relative; white-space: nowrap;
  padding: 10px 11px; font-size: 14px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink);
}
.nav a::after {
  content: ""; position: absolute; left: 11px; right: 11px; bottom: 4px; height: 2px;
  background: var(--orange); transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.nav a:hover { color: var(--orange); }
.nav a:hover::after, .nav a.active::after { transform: scaleX(1); }
.nav a.active { color: var(--orange); }
.nav .btn { margin-left: 12px; padding: 11px 22px; text-transform: none; letter-spacing: .02em; font-size: 14px; }
.nav .btn::after { display: none; }
.nav .btn, .nav .btn:hover { color: #fff; }

.menu-toggle {
  display: none; width: 44px; height: 44px; border: 0; background: none; cursor: pointer;
  border-radius: 10px; color: var(--ink);
}
.menu-toggle span { display: block; width: 22px; height: 2px; background: currentColor; margin: 5px auto; transition: transform .25s, opacity .25s; }
.menu-open .menu-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-open .menu-toggle span:nth-child(2) { opacity: 0; }
.menu-open .menu-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: radial-gradient(1200px 600px at 85% -10%, rgba(232, 130, 30, .22), transparent 60%),
              linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 100%);
  color: #c7d0d9;
  padding: 120px 0 128px;
}
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(180deg, #000 0%, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 90%);
}
.hero .container { position: relative; z-index: 1; display: grid; grid-template-columns: 1.25fr 1fr; gap: 64px; align-items: center; }
.hero h1 { color: #fff; font-size: clamp(42px, 6.2vw, 76px); line-height: 1.04; letter-spacing: -.01em; margin-bottom: 28px; }
.hero h1 em { font-style: normal; color: var(--orange-bright); }
.hero .lead { font-size: 20px; max-width: 540px; color: #b6c2ce; margin-bottom: 40px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-mark {
  position: relative; aspect-ratio: 1; max-width: 420px; justify-self: end; width: 100%;
}
.hero-mark .ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .12);
}
.hero-mark .ring:nth-child(2) { inset: 14%; border-color: rgba(255, 255, 255, .16); }
.hero-mark .ring:nth-child(3) { inset: 28%; border-color: rgba(232, 130, 30, .45); }
.hero-mark .core {
  position: absolute; inset: 36%; border-radius: 22px; background: var(--orange);
  display: grid; place-items: center;
  font-family: var(--sans); font-weight: 900; color: #fff; font-size: clamp(36px, 5vw, 58px); letter-spacing: -.02em;
  box-shadow: 0 30px 60px rgba(210, 105, 30, .35);
}
.hero-mark .chip {
  position: absolute; display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; border-radius: 999px;
  background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  color: #fff; font-size: 14px; font-weight: 700; white-space: nowrap;
  animation: float 6s ease-in-out infinite;
}
.hero-mark .chip b { color: var(--orange-bright); font-family: var(--serif); font-size: 18px; }
.hero-mark .chip.c1 { top: 8%; left: -4%; }
.hero-mark .chip.c2 { top: 46%; right: -8%; animation-delay: -2s; }
.hero-mark .chip.c3 { bottom: 6%; left: 6%; animation-delay: -4s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* Page hero (inner pages) */
.page-hero {
  position: relative; overflow: hidden;
  background: radial-gradient(900px 400px at 90% -20%, rgba(232, 130, 30, .25), transparent 60%),
              linear-gradient(160deg, var(--navy) 0%, var(--navy-2) 100%);
  color: #b6c2ce; padding: 88px 0 80px;
}
.page-hero h1 { color: #fff; font-size: clamp(36px, 5vw, 56px); margin-bottom: 14px; }
.page-hero p { font-size: 19px; max-width: 640px; margin: 0; }
.crumbs { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: #8396a8; margin-bottom: 18px; }
.crumbs a { color: #8396a8; }
.crumbs a:hover { color: #fff; }
.crumbs .sep { margin: 0 8px; color: var(--orange-bright); }
.crumbs [aria-current] { color: #c7d0d9; }

/* ---------- Stats strip ---------- */
.stats { margin-top: -56px; position: relative; z-index: 2; }
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); overflow: hidden;
}
.stat { padding: 32px 28px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat .num { font-family: var(--serif); font-size: 40px; font-weight: 700; color: var(--navy); line-height: 1; margin-bottom: 8px; }
.stat .num span { color: var(--orange); }
.stat .label { font-size: 14px; color: var(--muted); line-height: 1.5; }

/* ---------- Intro / split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.split--reverse > :first-child { order: 2; }
.intro-copy h2 { font-size: clamp(30px, 4vw, 44px); }
.intro-copy .tagline { font-family: var(--serif); font-size: 22px; color: var(--orange); margin-bottom: 22px; }
.pill-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 26px; padding: 0; list-style: none; }
.pill-list li {
  padding: 7px 14px; border-radius: 999px; background: var(--orange-tint); color: var(--orange-dark);
  font-size: 14px; font-weight: 700;
}
.signoff { font-family: var(--serif); font-size: 21px; color: var(--ink); border-left: 3px solid var(--orange); padding-left: 18px; margin: 28px 0 32px; }
.signoff span { display: block; color: var(--orange); }

.media-frame { position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-lg); }
.media-frame img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3.4; }
.media-wrap { position: relative; }
.media-wrap::before {
  content: ""; position: absolute; inset: 28px -28px -28px 28px; border-radius: var(--radius);
  border: 2px solid var(--orange); z-index: -1;
}
.media-badge {
  position: absolute; left: -28px; bottom: 36px; background: var(--navy); color: #fff;
  padding: 20px 24px; border-radius: 12px; box-shadow: var(--shadow-lg); max-width: 240px;
}
.media-badge b { display: block; font-family: var(--serif); font-size: 34px; color: var(--orange-bright); line-height: 1.1; }
.media-badge small { font-size: 14px; color: #b6c2ce; line-height: 1.4; display: block; }

/* ---------- Service cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 36px 32px; transition: transform .25s, box-shadow .25s, border-color .25s;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.card .icon {
  width: 56px; height: 56px; border-radius: 14px; background: var(--orange-tint); color: var(--orange);
  display: grid; place-items: center; margin-bottom: 24px; transition: background .25s, color .25s;
}
.card:hover .icon { background: var(--orange); color: #fff; }
.card .icon svg { width: 28px; height: 28px; }
.card h3 { font-size: 24px; margin-bottom: 10px; }
.card p { font-size: 16px; margin-bottom: 22px; }
.card .more { margin-top: auto; font-weight: 700; font-size: 14px; letter-spacing: .04em; display: inline-flex; align-items: center; gap: 8px; }
.card .more svg { width: 16px; height: 16px; transition: transform .2s; }
.card:hover .more svg { transform: translateX(4px); }
.card--cta {
  background: linear-gradient(160deg, var(--navy), var(--navy-3)); border-color: transparent; color: #b6c2ce;
}
.card--cta h3 { color: #fff; }
.card--cta .more { color: var(--orange-bright); }

/* ---------- Feature list (why choose) ---------- */
.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.feature {
  display: flex; gap: 18px; padding: 26px; border-radius: var(--radius);
  background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .08);
  transition: background .25s, border-color .25s;
}
.feature:hover { background: rgba(255, 255, 255, .07); border-color: rgba(232, 130, 30, .4); }
.feature .icon {
  flex: 0 0 48px; height: 48px; border-radius: 12px; background: rgba(232, 130, 30, .14); color: var(--orange-bright);
  display: grid; place-items: center;
}
.feature .icon svg { width: 24px; height: 24px; }
.feature h3 { font-size: 20px; margin-bottom: 6px; }
.feature p { font-size: 15.5px; margin: 0; color: #a9b7c4; }
.section:not(.section--navy) .feature { background: #fff; border-color: var(--line); }
.section:not(.section--navy) .feature:hover { box-shadow: var(--shadow); border-color: transparent; }
.section:not(.section--navy) .feature .icon { background: var(--orange-tint); color: var(--orange); }
.section:not(.section--navy) .feature p { color: var(--text); }

/* ---------- Industries ---------- */
.industries { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.industry {
  padding: 32px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line);
  border-top: 4px solid var(--orange);
}
.industry h3 { font-size: 22px; margin-bottom: 8px; }
.industry p { margin: 0; font-size: 16px; }

/* ---------- Practice detail ---------- */
.practice-nav {
  position: sticky; top: var(--header-h); z-index: 20; background: #fff; border-bottom: 1px solid var(--line);
}
.practice-nav .container { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-top: 12px; padding-bottom: 12px; }
.practice-nav .container::-webkit-scrollbar { display: none; }
.practice-nav a {
  white-space: nowrap; padding: 9px 18px; border-radius: 999px; font-size: 14px; font-weight: 700; color: var(--text);
  border: 1px solid var(--line); transition: all .2s;
}
.practice-nav a:hover, .practice-nav a.active { background: var(--navy); border-color: var(--navy); color: #fff; }

.practice { padding: 96px 0; border-bottom: 1px solid var(--line); }
.practice:nth-of-type(even) { background: var(--bg-soft); }
.practice .container { display: grid; grid-template-columns: 300px 1fr; gap: 72px; align-items: start; }
.practice-aside { position: sticky; top: calc(var(--header-h) + 90px); }
.practice-aside img { border-radius: var(--radius); box-shadow: var(--shadow); aspect-ratio: 1; object-fit: cover; width: 100%; margin-bottom: 24px; }
.practice-aside .index { font-family: var(--serif); font-size: 15px; color: var(--muted); letter-spacing: .1em; }
.practice h2 { font-size: clamp(32px, 4vw, 44px); margin-bottom: 22px; }
.practice .lede { font-size: 20px; color: var(--ink); line-height: 1.6; }
.callout {
  margin: 30px 0 0; padding: 26px 30px; border-radius: var(--radius); background: var(--navy); color: #c7d0d9;
  font-family: var(--serif); font-size: 19px; line-height: 1.55; position: relative;
}
.callout::before {
  content: ""; position: absolute; left: 0; top: 22px; bottom: 22px; width: 4px; background: var(--orange-bright); border-radius: 0 4px 4px 0;
}
.callout strong { color: var(--orange-bright); font-weight: 400; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 24px; padding: 0; list-style: none; }
.tags li { padding: 6px 12px; border-radius: 6px; background: #fff; border: 1px solid var(--line); font-size: 14px; color: var(--ink); }
.practice:nth-of-type(odd) .tags li { background: var(--bg-soft); }

/* ---------- Profile ---------- */
.profile { display: grid; grid-template-columns: 360px 1fr; gap: 72px; align-items: start; }
.profile-card {
  position: sticky; top: calc(var(--header-h) + 24px);
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); overflow: hidden;
}
.profile-photo { background: #fff; border-bottom: 3px solid var(--orange); }
.profile-photo img { width: 100%; aspect-ratio: 16 / 15; object-fit: cover; object-position: center top; }
.profile-meta { padding: 26px 28px 30px; }
.profile-meta h3 { font-size: 26px; margin-bottom: 2px; }
.profile-meta .role { color: var(--orange); font-weight: 700; font-size: 14px; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 18px; }
.profile-meta ul { list-style: none; margin: 0 0 22px; padding: 0; font-size: 15px; }
.profile-meta li { display: flex; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); }
.profile-meta li svg { flex: 0 0 18px; width: 18px; height: 18px; color: var(--orange); margin-top: 4px; }
.profile-body h2 { font-size: clamp(32px, 4vw, 44px); }
.profile-body .lede { font-size: 21px; color: var(--ink); font-family: var(--serif); line-height: 1.55; }
.sectors { display: flex; flex-wrap: wrap; gap: 10px; margin: 8px 0 28px; padding: 0; list-style: none; }
.sectors li { padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); font-size: 15px; font-weight: 700; color: var(--navy); background: #fff; }

/* ---------- Links (Client Zone) ---------- */
.link-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.link-card {
  display: flex; align-items: center; gap: 20px; padding: 26px 28px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--line); color: var(--ink); transition: all .25s;
}
.link-card:hover { box-shadow: var(--shadow-lg); border-color: transparent; transform: translateY(-3px); color: var(--ink); }
.link-card .icon {
  flex: 0 0 52px; height: 52px; border-radius: 12px; background: var(--orange-tint); color: var(--orange);
  display: grid; place-items: center; transition: all .25s;
}
.link-card:hover .icon { background: var(--orange); color: #fff; }
.link-card .icon svg { width: 24px; height: 24px; }
.link-card h3 { font-size: 20px; margin: 0 0 2px; }
.link-card p { margin: 0; font-size: 14.5px; color: var(--muted); }
.link-card .ext { margin-left: auto; color: var(--muted); flex: 0 0 20px; }
.link-card .ext svg { width: 20px; height: 20px; }
.link-card:hover .ext { color: var(--orange); }
.note { margin-top: 28px; font-size: 14.5px; color: var(--muted); }

/* ---------- Publications ---------- */
.article-list { display: grid; gap: 20px; }
.article-card { display: block; padding: 32px 36px; background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--orange); border-radius: var(--radius); color: var(--text); transition: transform .25s, box-shadow .25s; }
.article-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); color: var(--text); }
.article-card h3 { font-size: clamp(22px, 2.6vw, 28px); margin: 10px 0 10px; }
.article-card p { margin: 0 0 16px; font-size: 16px; }
.article-card .more { font-weight: 700; font-size: 14px; color: var(--orange); display: inline-flex; align-items: center; gap: 8px; }
.article-card .more svg { width: 16px; height: 16px; transition: transform .2s; }
.article-card:hover .more svg { transform: translateX(4px); }
.article-card-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; font-size: 13.5px; color: var(--muted); }
.article-card-meta .tag { background: var(--orange-tint); color: var(--orange-dark); font-weight: 700; padding: 3px 10px; border-radius: 999px; font-size: 12.5px; letter-spacing: .04em; text-transform: uppercase; }
.follow-note { margin-top: 28px; font-size: 15px; color: var(--muted); }
.empty {
  text-align: center; padding: 72px 32px; border-radius: var(--radius); border: 2px dashed var(--line); background: #fff;
}
.empty .icon { width: 72px; height: 72px; border-radius: 50%; background: var(--orange-tint); color: var(--orange); display: grid; place-items: center; margin: 0 auto 22px; }
.empty .icon svg { width: 32px; height: 32px; }
.empty h3 { font-size: 28px; }
.empty p { max-width: 520px; margin: 0 auto 28px; }

/* ---------- Contact ---------- */
.contact-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 920px) { .contact-cards { grid-template-columns: 1fr 1fr; } .contact-cards .info-item:first-child { grid-column: 1 / -1; } }
.info-item { display: flex; gap: 18px; padding: 24px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); }
.info-item .icon { flex: 0 0 48px; height: 48px; border-radius: 12px; background: var(--orange-tint); color: var(--orange); display: grid; place-items: center; }
.info-item .icon svg { width: 22px; height: 22px; }
.info-item h3 { font-family: var(--sans); font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 2px 0 4px; }
.info-item p, .info-item a { margin: 0; font-size: 17px; color: var(--ink); font-weight: 700; line-height: 1.55; }
.info-item a:hover { color: var(--orange); }

/* ---------- CTA band ---------- */
.cta-band {
  position: relative; overflow: hidden; border-radius: 20px; padding: 64px;
  background: radial-gradient(600px 300px at 100% 0%, rgba(255, 255, 255, .18), transparent 60%),
              linear-gradient(135deg, var(--orange) 0%, var(--orange-bright) 100%);
  color: #fff; display: grid; grid-template-columns: 1.4fr auto; gap: 32px; align-items: center;
}
.cta-band h2 { color: #fff; font-size: clamp(28px, 3.6vw, 40px); margin-bottom: 8px; }
.cta-band p { margin: 0; font-size: 18px; color: rgba(255, 255, 255, .9); }
.cta-band .btn { background: var(--navy); color: #fff; }
.cta-band .btn:hover { background: #0c151e; }

/* ---------- Footer ---------- */
.site-footer { background: #0e1822; color: #8fa0b0; padding: 80px 0 0; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.3fr; gap: 48px; padding-bottom: 56px; }
.footer-brand p { max-width: 300px; }
.site-footer h4 { font-family: var(--sans); font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: #fff; margin-bottom: 18px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 10px; }
.site-footer a { color: #8fa0b0; }
.site-footer a:hover { color: var(--orange-bright); }
.socials { display: flex; gap: 10px; margin-top: 22px; }
.socials a {
  width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(255, 255, 255, .06); color: #fff; transition: background .2s;
}
.socials a:hover { background: var(--orange); color: #fff; }
.socials svg { width: 18px; height: 18px; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .08); padding: 24px 0; font-size: 13.5px;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}

/* ---------- Disclaimer modal ---------- */
.modal {
  position: fixed; inset: 0; z-index: 100; display: none; align-items: center; justify-content: center; padding: 16px;
  background: rgba(10, 18, 26, .72); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
}
.modal.open { display: flex; animation: fade .3s ease; }
.modal-box {
  background: #fff; border-radius: 18px; max-width: 560px; width: 100%; max-height: 92vh; overflow: auto;
  box-shadow: 0 40px 80px rgba(0, 0, 0, .35); animation: rise .35s ease;
}
.modal-head { background: var(--navy); color: #fff; padding: 28px 36px; display: flex; align-items: center; gap: 16px; }
.modal-head .seal { flex: 0 0 48px; height: 48px; border-radius: 12px; background: var(--orange); display: grid; place-items: center; }
.modal-head .seal svg { width: 24px; height: 24px; }
.modal-head h2 { color: #fff; font-size: 24px; margin: 0; }
.modal-head small { color: #9fb0c0; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; }
.modal-body { padding: 28px 36px 32px; font-size: 15.5px; }
.modal-body ul { padding-left: 20px; margin: 0 0 24px; }
.modal-body li { margin-bottom: 10px; }
.modal-body li::marker { color: var(--orange); }
.modal-body .btn { width: 100%; justify-content: center; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-mark .chip { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .practice .container { grid-template-columns: 220px 1fr; gap: 48px; }
  .profile { grid-template-columns: 300px 1fr; gap: 48px; }
}
@media (max-width: 1240px) {
  .menu-toggle { display: block; }
  .nav {
    position: fixed; top: var(--header-h); left: 0; right: 0; height: calc(100vh - var(--header-h)); height: calc(100dvh - var(--header-h));
    flex-direction: column; align-items: stretch; gap: 0; padding: 16px 24px 32px;
    background: #fff; overflow-y: auto;
    opacity: 0; transform: translateY(-8px); transition: opacity .25s ease, transform .25s ease, visibility .25s; visibility: hidden;
  }
  .menu-open .nav { opacity: 1; transform: none; visibility: visible; }
  .nav a { padding: 18px 4px; font-size: 16px; border-bottom: 1px solid var(--line); }
  .nav a::after { display: none; }
  .nav .btn { margin: 24px 0 0; justify-content: center; padding: 16px; border-bottom: 0; font-size: 16px; }
}
@media (max-width: 920px) {
  :root { --header-h: 68px; }
  body { font-size: 16.5px; }
  .section { padding: 80px 0; }

  .hero { padding: 80px 0 120px; }
  .hero .container { grid-template-columns: 1fr; gap: 56px; }
  .hero-mark { justify-self: center; max-width: 320px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .split { grid-template-columns: 1fr; gap: 56px; }
  .split--reverse > :first-child { order: 0; }
  .features, .industries { grid-template-columns: 1fr; }
  .practice { padding: 72px 0; }
  .practice .container { grid-template-columns: 1fr; gap: 28px; }
  .practice-aside { position: static; display: flex; align-items: center; gap: 18px; }
  .practice-aside img { width: 84px; margin: 0; border-radius: 12px; }
  .profile { grid-template-columns: 1fr; }
  .profile-card { position: static; max-width: 420px; }
  .cta-band { grid-template-columns: 1fr; padding: 44px 32px; }
  .media-badge { left: 16px; }
  .media-wrap::before { inset: 20px -12px -16px 20px; }
}
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .section { padding: 64px 0; }
  .cards, .link-grid, .contact-cards { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 36px; }
  .stat { padding: 24px 18px; }
  .stat .num { font-size: 32px; }
  .modal-head, .modal-body { padding-left: 22px; padding-right: 22px; }
  .hero-mark .chip { font-size: 12px; padding: 8px 12px; }
  .hero-mark .chip.c2 { right: -2%; }
  .hero-mark .chip.c1 { left: 0; }
  .link-card { padding: 20px; gap: 14px; }
}
.industry .icon svg { width: 32px; height: 32px; }

/* ---------- Logo (recreated from brand mark) ---------- */
.logo { display: inline-flex; align-items: center; gap: 8px; font-family: var(--sans); font-weight: 900; line-height: 1; letter-spacing: -.02em; }
.logo-ip { background: var(--orange-bright); color: #fff; font-size: 24px; padding: 7px 8px 6px; border-radius: 4px; }
.logo-word { position: relative; color: var(--navy); font-size: 30px; padding-right: 14px; }
.logo-word svg { position: absolute; right: 0; top: -2px; width: 12px; height: 12px; color: var(--orange-bright); }
.site-footer .logo-word { color: #fff; }
.footer-logo { display: inline-block; margin-bottom: 20px; }
@media (max-width: 920px) { .logo-ip { font-size: 20px; } .logo-word { font-size: 26px; } }
a.card, a.card:hover { color: var(--text); }
a.card .more { color: var(--orange); }
a.card--cta, a.card--cta:hover { color: #b6c2ce; }
a.card--cta .more { color: var(--orange-bright); }

/* ---------- Proprietary docketing system ---------- */
.docket { background: linear-gradient(180deg, #fff 0%, var(--bg-soft) 100%); }
.docket-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 72px; align-items: center; margin-bottom: 64px; }
.docket h2 { font-size: clamp(30px, 4vw, 44px); }
.docket .lede { font-size: 20px; color: var(--ink); line-height: 1.6; }
.docket .lede strong { color: var(--orange); }
.docket-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.docket-features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.dfeat { display: flex; gap: 16px; padding: 26px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); transition: box-shadow .25s, border-color .25s, transform .25s; }
.dfeat:hover { box-shadow: var(--shadow-lg); border-color: transparent; transform: translateY(-3px); }
.dfeat .icon { flex: 0 0 46px; height: 46px; border-radius: 12px; background: var(--orange-tint); color: var(--orange); display: grid; place-items: center; }
.dfeat .icon svg { width: 22px; height: 22px; }
.dfeat h3 { font-size: 19px; margin-bottom: 6px; }
.dfeat p { font-size: 15.5px; margin: 0; }

.docket-visual { border-radius: 16px; overflow: hidden; background: #fff; box-shadow: var(--shadow-lg); border: 1px solid var(--line); transform: perspective(1400px) rotateY(-6deg) rotateX(2deg); }
.dv-top { display: flex; align-items: center; gap: 6px; padding: 12px 16px; background: var(--navy); }
.dv-top span { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,.22); }
.dv-top span:first-child { background: var(--orange-bright); }
.dv-top b { margin-left: 10px; color: #fff; font-size: 13px; letter-spacing: .04em; }
.dv-body { display: grid; grid-template-columns: 56px 1fr; min-height: 300px; }
.dv-side { background: var(--orange); padding: 18px 12px; display: grid; gap: 10px; align-content: start; }
.dv-side i { display: block; height: 10px; border-radius: 4px; background: rgba(255,255,255,.4); }
.dv-side i.on { background: #fff; }
.dv-main { padding: 18px; }
.dv-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 16px; }
.dv-kpis div { padding: 12px; border-radius: 10px; background: var(--orange-tint); }
.dv-kpis small { display: block; font-size: 11px; font-weight: 700; color: var(--orange-dark); margin-bottom: 8px; line-height: 1.3; }
.dv-bar { display: block; height: 8px; border-radius: 4px; background: #e5ddd4; }
.dv-kpis .dv-bar { background: rgba(210,105,30,.35); height: 14px; }
.dv-row { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px; padding: 12px 4px; border-top: 1px solid var(--line); }
.dv-type { font-size: 12px; color: var(--muted); }
.dv-pill { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.dv-pill.ok { background: #e1f2e6; color: #1f6b38; }
.dv-pill.warn { background: #fff0d6; color: #8a4b00; }
.dv-pill.bad { background: #fbe3e0; color: #b3261e; }
.dv-pill.info { background: #e2ebf8; color: #1f4f99; }

.docket-card {
  display: grid; grid-template-columns: auto 1fr auto; gap: 28px; align-items: center;
  padding: 36px 40px; border-radius: 18px; background: linear-gradient(135deg, var(--navy), var(--navy-3));
  color: #b6c2ce; box-shadow: var(--shadow-lg); transition: transform .25s;
}
.docket-card:hover { color: #b6c2ce; transform: translateY(-3px); }
.docket-card .icon { width: 72px; height: 72px; border-radius: 18px; background: var(--orange); color: #fff; display: grid; place-items: center; }
.docket-card .icon svg { width: 34px; height: 34px; }
.docket-card .eyebrow { color: var(--orange-bright); }
.docket-card h2 { color: #fff; font-size: clamp(24px, 3vw, 32px); margin-bottom: 6px; }
.docket-card p { margin: 0; }

@media (max-width: 1080px) { .docket-features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 920px) {
  .docket-grid { grid-template-columns: 1fr; gap: 48px; }
  .docket-visual { transform: none; }
  .docket-card { grid-template-columns: 1fr; padding: 30px 24px; gap: 20px; }
  .docket-card .btn { justify-self: start; }
}
@media (max-width: 640px) {
  .docket-features { grid-template-columns: 1fr; }
  .dv-kpis { grid-template-columns: 1fr 1fr; }
  .dv-kpis div:last-child { display: none; }
  .dv-row { grid-template-columns: 1fr auto; }
  .dv-row .dv-bar { display: none; }
}

/* ---------- Clients ---------- */
.trusted { padding: 72px 0 8px; text-align: center; }
.trusted-label { font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-bottom: 28px; }
.trusted-logos { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 28px 56px; }
.trusted-logos img { height: 40px; width: auto; max-width: 180px; object-fit: contain; filter: grayscale(1); opacity: .65; transition: filter .3s, opacity .3s; }
.trusted-logos img.square { height: 64px; }
.trusted-logos img.wide { height: 36px; max-width: 200px; }
.trusted-logos img:hover { filter: none; opacity: 1; }
.trusted-more { margin: 28px 0 0; font-weight: 700; font-size: 14px; letter-spacing: .04em; }
.trusted-more a { display: inline-flex; align-items: center; gap: 8px; }
.trusted-more svg { width: 16px; height: 16px; }

.client-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.client { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .25s, box-shadow .25s, border-color .25s; }
.client:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: transparent; }
.client-logo { height: 170px; display: grid; place-items: center; padding: 28px 32px; }
.client-logo img { max-height: 64px; max-width: 220px; width: 100%; object-fit: contain; }
.client-logo img.square { max-height: 116px; width: auto; }
.client-logo img.wide { max-width: 230px; }
.client figcaption { border-top: 1px solid var(--line); padding: 18px 24px; display: flex; flex-direction: column; gap: 2px; }
.client figcaption b { font-family: var(--serif); font-size: 20px; color: var(--ink); }
.client figcaption span { font-size: 14px; color: var(--muted); }
@media (max-width: 920px) {
  .client-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .trusted-logos { gap: 24px 36px; }
  .trusted-logos img { height: 30px; }
  .trusted-logos img.square { height: 52px; }
  .client-grid { grid-template-columns: 1fr; }
  .client-logo { height: 150px; }
}

.trusted-logos img.wide { max-width: 170px; }
@media (max-width: 1080px) { .client-grid { grid-template-columns: repeat(2, 1fr); } .client-grid .client:last-child:nth-child(odd) { grid-column: 1 / -1; } }
.info-item a.map-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 14px; color: var(--orange); }
.info-item a.map-link svg { width: 14px; height: 14px; }
.info-item a.map-link:hover { color: var(--orange-dark); }
.map-cta { text-align: center; margin: 28px 0 0; }
/* Logos designed for dark backgrounds */
.client-logo:has(img.dark) { background: #0b0b0b; }
.trusted-logos img.dark { background: #0b0b0b; padding: 6px 10px; border-radius: 6px; height: 44px; box-sizing: content-box; }
@media (max-width: 640px) { .client-grid .client:last-child:nth-child(odd) { grid-column: auto; } .trusted-logos img.dark { height: 32px; } }

/* ---------- Article ---------- */
.container.narrow { max-width: 820px; }
.article-hero h1 { font-size: clamp(30px, 4.2vw, 46px); line-height: 1.15; }
.article-meta { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: 18px; font-size: 15px; color: #9fb0c0; }
.article-meta a { color: #fff; }
.article-meta a:hover { color: var(--orange-bright); }
.article { padding-top: 64px; }
.article-lead { font-family: var(--serif); font-size: 22px; line-height: 1.6; color: var(--ink); margin-bottom: 28px; }
.article-toc { background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 28px; margin-bottom: 40px; }
.article-toc b { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.article-toc ol { margin: 10px 0 0; padding-left: 20px; }
.article-toc li { margin: 4px 0; }
.article-toc li::marker { color: var(--orange); }
.prose { font-size: 18px; line-height: 1.8; color: #3a3f45; }
.prose h2 { font-size: clamp(26px, 3vw, 32px); margin: 52px 0 16px; scroll-margin-top: calc(var(--header-h) + 20px); }
.prose p { margin: 0 0 1.2em; }
.prose a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose strong { color: var(--ink); }
.prose ul, .prose ol { margin: 0 0 1.4em; padding-left: 24px; }
.prose li { margin-bottom: .7em; padding-left: 4px; }
.prose li::marker { color: var(--orange); font-weight: 700; }
.prose .table-wrap { overflow-x: auto; margin: 8px 0 32px; border: 1px solid var(--line); border-radius: var(--radius); }
.prose table { width: 100%; border-collapse: collapse; font-size: 15.5px; line-height: 1.5; min-width: 560px; }
.prose th, .prose td { padding: 14px 18px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.prose thead th { background: var(--navy); color: #fff; font-family: var(--sans); font-size: 14px; letter-spacing: .02em; }
.prose tbody th { color: var(--ink); background: var(--bg-soft); white-space: nowrap; }
.prose tbody tr:last-child th, .prose tbody tr:last-child td { border-bottom: 0; }
.article-cta { margin: 40px 0 24px; padding: 28px 32px; border-radius: var(--radius); background: var(--navy); color: #c7d0d9; font-size: 17px; line-height: 1.7; }
.article-cta strong { color: var(--orange-bright); display: block; font-family: var(--serif); font-size: 22px; margin-bottom: 6px; }
.article-cta a { color: #fff; }
.prose .disclaimer { font-size: 14.5px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 16px; }
.prose ul.sources { font-size: 15px; line-height: 1.6; }
.author-card { display: flex; gap: 20px; align-items: center; margin-top: 48px; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.author-card img { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; object-position: center 20%; flex: 0 0 88px; }
.author-card b { display: block; font-family: var(--serif); font-size: 20px; color: var(--ink); }
.author-card span { display: block; font-size: 15px; margin: 4px 0 8px; line-height: 1.55; }
.author-card a { font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; gap: 6px; }
.author-card a svg { width: 15px; height: 15px; }
.back-link { margin-top: 28px; font-weight: 700; }
@media (max-width: 640px) {
  .article-card { padding: 24px 20px; }
  .article-lead { font-size: 19px; }
  .prose { font-size: 17px; }
  .article-cta { padding: 22px 20px; }
  .author-card { flex-direction: column; align-items: flex-start; }
}

/* ---------- Nav dropdown (desktop) / accordion (mobile) ---------- */
.nav-group { position: relative; }
.nav-group-btn {
  display: inline-flex; align-items: center; gap: 4px; background: none; border: 0; cursor: pointer;
  padding: 10px 11px; font: inherit; font-size: 14px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink); white-space: nowrap; position: relative;
}
.nav-group-btn svg { width: 12px; height: 12px; transition: transform .2s; }
.nav-group-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.nav-group-btn::after {
  content: ""; position: absolute; left: 11px; right: 27px; bottom: 4px; height: 2px;
  background: var(--orange); transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.nav-group-btn:hover, .nav-group.active > .nav-group-btn { color: var(--orange); }
.nav-group-btn:hover::after, .nav-group.active > .nav-group-btn::after { transform: scaleX(1); }
.nav-group-btn:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; border-radius: 6px; }
.nav-sub {
  display: none; position: absolute; top: calc(100% + 6px); left: 0; min-width: 240px; z-index: 60;
  list-style: none; margin: 0; padding: 8px; background: #fff; border: 1px solid var(--line);
  border-radius: 12px; box-shadow: var(--shadow-lg);
}
.nav-sub::before { content: ""; position: absolute; top: -8px; left: 0; right: 0; height: 8px; } /* hover bridge */
.nav-group-btn[aria-expanded="true"] + .nav-sub { display: block; }
.nav .nav-sub a {
  display: block; padding: 10px 14px; border-radius: 8px; text-transform: none; letter-spacing: 0;
  font-size: 15px; font-weight: 700; color: var(--ink);
}
.nav .nav-sub a::after { display: none; }
.nav .nav-sub a:hover, .nav .nav-sub a:focus-visible { background: var(--orange-tint); color: var(--orange-dark); outline: none; }
.nav .nav-sub a[aria-current="page"] { color: var(--orange); }
@media (max-width: 1240px) {
  .nav-group { border-bottom: 1px solid var(--line); }
  .nav-group-btn { width: 100%; justify-content: space-between; padding: 18px 4px; font-size: 16px; }
  .nav-group-btn::after { display: none; }
  .nav-group-btn svg { width: 16px; height: 16px; }
  .nav-sub { position: static; box-shadow: none; border: 0; border-radius: 0; padding: 0 0 12px 12px; min-width: 0; }
  .nav-sub::before { display: none; }
  .nav .nav-sub a { padding: 12px 8px; font-size: 16px; border-bottom: 0; }
}

/* ---------- Client Zone tools ---------- */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.tool-card {
  display: flex; flex-direction: column; gap: 16px; padding: 32px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--line); color: var(--text); transition: transform .25s, box-shadow .25s, border-color .25s;
}
.tool-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: transparent; color: var(--text); }
.tool-card .icon { width: 56px; height: 56px; border-radius: 14px; background: var(--navy); color: #fff; display: grid; place-items: center; flex: 0 0 56px; }
.tool-card .icon svg { width: 28px; height: 28px; }
.tool-card h3 { font-size: 24px; margin: 0 0 4px; }
.tool-card p { margin: 0; font-size: 16px; }
.tool-card .more { margin-top: auto; font-weight: 700; font-size: 14px; color: var(--orange); display: inline-flex; align-items: center; gap: 8px; }
.tool-card .more svg { width: 16px; height: 16px; transition: transform .2s; }
.tool-card:hover .more svg { transform: translateX(4px); }
/* A single tool spans the row as a featured card, so the grid looks deliberate until more tools arrive */
.tool-grid > .tool-card:only-child {
  grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 28px; padding: 36px 40px;
  background: linear-gradient(135deg, var(--navy), var(--navy-3)); border-color: transparent; color: #c7d0d9;
}
.tool-grid > .tool-card:only-child h3 { color: #fff; }
.tool-grid > .tool-card:only-child .icon { background: var(--orange); width: 72px; height: 72px; flex-basis: 72px; border-radius: 18px; }
.tool-grid > .tool-card:only-child .icon svg { width: 34px; height: 34px; }
.tool-grid > .tool-card:only-child .tool-card-body { flex: 1; }
.tool-grid > .tool-card:only-child .more { margin: 0; color: var(--orange-bright); white-space: nowrap; }
@media (max-width: 720px) {
  .tool-grid > .tool-card:only-child { flex-direction: column; align-items: flex-start; padding: 28px 24px; }
}

/* ---------- Nice Class Finder ---------- */
.finder-section { padding-top: 64px; }
.finder-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; }
.finder-main { min-width: 0; }
.finder-panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.finder-label { display: block; font-weight: 700; color: var(--ink); margin-bottom: 10px; }
.search-box { position: relative; }
.search-box svg { position: absolute; left: 16px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search-box input {
  width: 100%; font: inherit; font-size: 17px; color: var(--ink); background: var(--bg-soft);
  border: 1px solid #d9d3cc; border-radius: 10px; transition: border-color .2s, box-shadow .2s, background .2s;
}
.search-box input { padding: 14px 16px 14px 46px; }
.search-box input:focus { outline: none; border-color: var(--orange); background: #fff; box-shadow: 0 0 0 4px rgba(210, 105, 30, .14); }
.hint { margin: 10px 0 0; font-size: 14px; color: var(--muted); }
.finder-status { margin: 18px 2px 0; font-size: 15px; color: var(--muted); min-height: 1.4em; }
.finder-status.error { color: #8a2d00; background: #fff3e8; border: 1px solid #f3d3b8; padding: 12px 16px; border-radius: 10px; }
.finder-results { display: grid; gap: 16px; margin-top: 12px; }
.finder-results[aria-busy="true"] { opacity: .55; }
.spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid var(--line); border-top-color: var(--orange); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -3px; margin-right: 8px; }
@keyframes spin { to { transform: rotate(360deg); } }

.class-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.class-card-head { display: flex; gap: 14px; align-items: flex-start; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.class-badge { flex: 0 0 auto; min-width: 54px; text-align: center; padding: 6px 10px; border-radius: 10px; background: var(--navy); color: #fff; font-weight: 900; font-size: 15px; line-height: 1.2; }
.class-badge small { display: block; font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #9fb0c0; }
.class-card-title { flex: 1; min-width: 0; }
.class-card-title h3 { font-family: var(--sans); font-size: 15.5px; font-weight: 700; line-height: 1.5; margin: 0; color: var(--ink); }
.class-card-title a { font-size: 13.5px; font-weight: 700; }
.term-list { list-style: none; margin: 0; padding: 6px 0; }
.term-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 20px; }
.term-list li + li { border-top: 1px solid #f3efe9; }
.term-text { font-size: 15.5px; color: var(--ink); min-width: 0; overflow-wrap: anywhere; }
.term-text mark { background: #ffe3cc; color: inherit; border-radius: 3px; padding: 0 1px; }
.add-btn {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px;
  border: 1px solid var(--orange); background: #fff; color: var(--orange-dark); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer;
  transition: background .15s, color .15s;
}
.add-btn:hover { background: var(--orange); color: #fff; }
.add-btn:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
.add-btn[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.show-more { display: block; width: 100%; padding: 12px; border: 0; border-top: 1px solid var(--line); background: var(--bg-soft); font: inherit; font-size: 14px; font-weight: 700; color: var(--orange-dark); cursor: pointer; }
.show-more:hover { background: var(--orange-tint); }

.spec-panel { position: sticky; top: calc(var(--header-h) + 20px); background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.spec-panel h2 { font-size: 22px; margin-bottom: 12px; }
.spec-empty { font-size: 15px; color: var(--muted); margin: 0 0 16px; }
.spec-class { margin-bottom: 14px; }
.spec-class h3 { font-family: var(--sans); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 6px; }
.spec-class ul { list-style: none; margin: 0; padding: 0; }
.spec-class li { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; font-size: 14.5px; padding: 4px 0; color: var(--ink); line-height: 1.45; }
.spec-remove { flex: 0 0 auto; border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 18px; line-height: 1; padding: 0 4px; border-radius: 4px; }
.spec-remove:hover, .spec-remove:focus-visible { color: #b3261e; outline: none; background: #fbe3e0; }
.spec-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.spec-actions .btn { padding: 11px 18px; font-size: 14px; }
.spec-actions .btn:disabled { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }
.spec-copied { font-size: 14px; color: #1f6b38; font-weight: 700; margin: 10px 0 0; min-height: 1.2em; }

.finder-disclaimer {
  display: flex; gap: 12px; align-items: flex-start; margin: 28px 0 0; padding: 16px 20px; border-radius: 12px;
  background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--orange); font-size: 15px; color: var(--ink);
}
.finder-disclaimer svg { flex: 0 0 20px; width: 20px; height: 20px; color: var(--orange); margin-top: 2px; }
.finder-source { font-size: 14px; color: var(--muted); margin: 14px 0 0; }
.finder-help { margin: 28px 0 0; font-size: 16px; }
.faqs { display: grid; gap: 12px; }
.faq { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 20px; }
.faq summary { cursor: pointer; list-style: none; padding: 18px 28px 18px 0; font-weight: 700; color: var(--ink); position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 14px; font-size: 22px; color: var(--orange); }
.faq[open] summary::after { content: "\2212"; }
.faq p { margin: 0 0 18px; }

@media (max-width: 1080px) {
  .finder-layout { grid-template-columns: 1fr; }
  .spec-panel { position: static; }
}
@media (max-width: 640px) {
  .finder-panel { padding: 18px; }
  .term-list li { padding: 8px 14px; }
  .class-card-head { padding: 16px 14px; }
}

/* ---------- Nice class pages ---------- */
.class-group-title { font-size: 26px; margin: 40px 0 16px; }
.class-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.class-tile { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; background: #fff; border: 1px solid var(--line); border-radius: 12px; color: var(--text); transition: box-shadow .2s, border-color .2s; }
.class-tile:hover { box-shadow: var(--shadow); border-color: var(--orange); color: var(--text); }
.class-tile b { font-family: var(--serif); font-size: 19px; color: var(--ink); }
.class-tile span { font-size: 14.5px; line-height: 1.45; }
.index-cta { margin: 0 0 8px; }
.class-page h2 { font-size: clamp(24px, 3vw, 30px); margin: 40px 0 12px; }
.class-page h2:first-child { margin-top: 0; }
.class-page h3 { font-family: var(--sans); font-size: 16px; margin: 22px 0 8px; }
.class-page ul { padding-left: 22px; }
.class-page li { margin-bottom: 6px; }
.class-page li::marker { color: var(--orange); }
.class-heading { font-family: var(--serif); font-size: 20px; color: var(--ink); line-height: 1.6; }
.term-sample { columns: 2; column-gap: 32px; }
.term-sample li { break-inside: avoid; }
.class-pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--line); font-weight: 700; }
@media (max-width: 640px) { .term-sample { columns: 1; } }
/* Long official headings (e.g. Class 9) are clamped in result cards; the full text is on the class page and in the title tooltip */
.class-card-title h3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
