/* ─── Reset & Base ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:       #0d1f3c;
  --navy-light: #1a3358;
  --blue:       #1d4ed8;
  --blue-light: #3b82f6;
  --bg:         #f1f5f9;
  --card:       #ffffff;
  --border:     #e2e8f0;
  --text:       #1e293b;
  --muted:      #64748b;
  --green:      #059669;
  --amber:      #d97706;
  --red:        #dc2626;
  --radius:     6px;
  --shadow:     0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
  --shadow-md:  0 4px 6px rgba(0,0,0,.07), 0 2px 4px rgba(0,0,0,.06);
}

html  { font-size: 16px; }
body  { font-family: 'Inter', system-ui, sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; }
a     { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── Layout ────────────────────────────────────────────────────────────────── */
.container    { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.main-content { padding: 32px 0 64px; }

/* ─── Header ────────────────────────────────────────────────────────────────── */
.site-header  { background: var(--navy); padding: 0; position: sticky; top: 0; z-index: 100; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.site-header .container { display: flex; align-items: center; gap: 32px; height: 60px; }

.logo         { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.logo-mark    { background: var(--blue); color: #fff; font-weight: 700; font-size: 14px; width: 30px; height: 30px; border-radius: 4px; display: flex; align-items: center; justify-content: center; }
.logo-text    { color: #fff; font-weight: 600; font-size: 16px; }

.main-nav     { display: flex; gap: 4px; overflow-x: auto; }
.nav-link     { color: rgba(255,255,255,.75); padding: 6px 12px; border-radius: var(--radius); font-size: 13px; font-weight: 500; white-space: nowrap; transition: all .15s; }
.nav-link:hover, .nav-link.active { color: #fff; background: var(--navy-light); text-decoration: none; }

/* ─── Jurisdiction bar ───────────────────────────────────────────────────────── */
.jurisdiction-bar { background: #fff; border-bottom: 1px solid var(--border); }
.jurisdiction-bar .container { display: flex; align-items: center; gap: 24px; height: 44px; }
.jur-label    { font-weight: 600; font-size: 14px; color: var(--navy); }
.jur-nav      { display: flex; gap: 4px; }
.jur-nav a    { font-size: 13px; color: var(--muted); padding: 4px 12px; border-radius: var(--radius); transition: all .15s; }
.jur-nav a:hover, .jur-nav a.active { color: var(--blue); background: #eff6ff; text-decoration: none; }

/* ─── Page heading ───────────────────────────────────────────────────────────── */
.page-header  { margin-bottom: 24px; }
.page-header h1 { font-size: 24px; font-weight: 700; color: var(--navy); }
.page-header p  { color: var(--muted); margin-top: 4px; font-size: 14px; }

/* ─── Search / Filter bar ────────────────────────────────────────────────────── */
.search-bar   { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; margin-bottom: 20px; display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.search-bar input, .search-bar select { height: 38px; border: 1px solid var(--border); border-radius: var(--radius); padding: 0 12px; font-size: 14px; font-family: inherit; color: var(--text); background: #fff; }
.search-bar input { flex: 1; min-width: 200px; }
.search-bar select { min-width: 160px; }
.search-bar input:focus, .search-bar select:focus { outline: none; border-color: var(--blue-light); box-shadow: 0 0 0 3px rgba(59,130,246,.15); }
.btn { height: 38px; padding: 0 20px; border: none; border-radius: var(--radius); font-size: 14px; font-weight: 500; cursor: pointer; transition: all .15s; font-family: inherit; }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: #1e40af; }
.btn-ghost { background: transparent; border: 1px solid var(--border); color: var(--muted); }
.btn-ghost:hover { border-color: var(--blue-light); color: var(--blue); }

/* ─── Results meta ───────────────────────────────────────────────────────────── */
.results-meta { font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.results-meta strong { color: var(--text); }

/* ─── Table ───────────────────────────────────────────────────────────────────── */
.data-table   { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.data-table thead th { background: var(--navy); color: rgba(255,255,255,.85); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; padding: 12px 16px; text-align: left; white-space: nowrap; }
.data-table tbody tr { border-bottom: 1px solid var(--border); transition: background .1s; }
.data-table tbody tr:last-child { border-bottom: none; }
.data-table tbody tr:hover { background: #f8fafc; }
.data-table td { padding: 13px 16px; font-size: 14px; vertical-align: middle; }
.data-table td.name a { font-weight: 600; color: var(--navy); }
.data-table td.name a:hover { color: var(--blue); text-decoration: none; }
.data-table td.muted { color: var(--muted); }
.data-table td.num { font-variant-numeric: tabular-nums; }

/* ─── Badges ─────────────────────────────────────────────────────────────────── */
.badge        { display: inline-block; font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 99px; text-transform: uppercase; letter-spacing: .04em; }
.badge-green  { background: #d1fae5; color: #065f46; }
.badge-amber  { background: #fef3c7; color: #92400e; }
.badge-red    { background: #fee2e2; color: #991b1b; }
.badge-gray   { background: #f1f5f9; color: #475569; }
.badge-blue   { background: #dbeafe; color: #1e40af; }

/* ─── Pagination ─────────────────────────────────────────────────────────────── */
.pagination   { display: flex; gap: 4px; justify-content: center; margin-top: 24px; }
.pagination a, .pagination span { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: var(--radius); font-size: 14px; border: 1px solid var(--border); background: #fff; color: var(--text); text-decoration: none; transition: all .15s; }
.pagination a:hover { border-color: var(--blue-light); color: var(--blue); }
.pagination .current { background: var(--blue); border-color: var(--blue); color: #fff; }
.pagination .ellipsis { border: none; background: transparent; }

/* ─── Profile page ───────────────────────────────────────────────────────────── */
.profile-header { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 28px 32px; margin-bottom: 24px; box-shadow: var(--shadow); }
.profile-header h1 { font-size: 28px; font-weight: 700; color: var(--navy); }
.profile-meta { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 10px; font-size: 14px; color: var(--muted); }
.profile-meta span { display: flex; align-items: center; gap: 6px; }
.profile-meta strong { color: var(--text); }

.stats-grid   { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card    { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.stat-card .value { font-size: 28px; font-weight: 700; color: var(--navy); line-height: 1; }
.stat-card .label { font-size: 12px; color: var(--muted); margin-top: 6px; text-transform: uppercase; letter-spacing: .04em; font-weight: 500; }

.profile-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 24px; }
@media (max-width: 768px) { .profile-grid { grid-template-columns: 1fr; } }

.card         { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); margin-bottom: 24px; }
.card h3      { font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: 16px; }
.card p       { font-size: 15px; line-height: 1.7; color: var(--text); }

.detail-list  { list-style: none; }
.detail-list li { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.detail-list li:last-child { border-bottom: none; }
.detail-list .key   { color: var(--muted); }
.detail-list .value { font-weight: 500; color: var(--text); text-align: right; }

.tag-list     { display: flex; flex-wrap: wrap; gap: 8px; }
.tag          { background: #eff6ff; color: var(--blue); border-radius: 4px; padding: 4px 10px; font-size: 13px; font-weight: 500; }

.gated        { background: #f8fafc; border: 1px dashed var(--border); border-radius: var(--radius); padding: 20px; text-align: center; color: var(--muted); font-size: 14px; }
.gated strong { display: block; font-size: 15px; color: var(--text); margin-bottom: 6px; }

/* ─── Homepage ───────────────────────────────────────────────────────────────── */
.hero         { background: var(--navy); color: #fff; padding: 64px 0 56px; margin-bottom: 0; }
.hero h1      { font-size: 40px; font-weight: 700; line-height: 1.2; max-width: 600px; }
.hero p       { font-size: 18px; color: rgba(255,255,255,.75); margin-top: 16px; max-width: 540px; }
.hero-search  { margin-top: 32px; display: flex; gap: 12px; max-width: 500px; }
.hero-search input { flex: 1; height: 46px; border: none; border-radius: var(--radius); padding: 0 16px; font-size: 15px; }
.hero-search .btn { height: 46px; padding: 0 28px; font-size: 15px; }

.jur-cards    { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-top: 40px; }
.jur-card     { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); transition: box-shadow .2s, transform .2s; }
.jur-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); text-decoration: none; }
.jur-card .flag { font-size: 28px; }
.jur-card h3  { font-size: 16px; font-weight: 600; color: var(--navy); margin-top: 8px; }
.jur-card p   { font-size: 13px; color: var(--muted); margin-top: 4px; }

/* ─── Admin ──────────────────────────────────────────────────────────────────── */
.admin-header { background: #1e293b; color: #fff; padding: 12px 0; margin-bottom: 24px; }
.admin-header .container { display: flex; align-items: center; gap: 16px; }
.admin-header h2 { font-size: 14px; font-weight: 600; }
.admin-grid   { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.admin-card   { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
.admin-card h3 { font-size: 15px; font-weight: 600; margin-bottom: 8px; }
.admin-card .big-num { font-size: 32px; font-weight: 700; color: var(--navy); }
.log          { background: #1e293b; color: #94a3b8; font-family: monospace; font-size: 13px; padding: 16px; border-radius: var(--radius); max-height: 400px; overflow-y: auto; }
.log .ok      { color: #34d399; }
.log .err     { color: #f87171; }
.log .info    { color: #60a5fa; }

/* ─── Utility ────────────────────────────────────────────────────────────────── */
.mt-0 { margin-top: 0; } .mt-4 { margin-top: 16px; } .mt-8 { margin-top: 32px; }
.text-muted { color: var(--muted); font-size: 14px; }
.empty-state { text-align: center; padding: 64px 0; color: var(--muted); }
.empty-state h3 { font-size: 18px; color: var(--text); margin-bottom: 8px; }

/* ─── Footer ─────────────────────────────────────────────────────────────────── */
.site-footer  { background: var(--navy); color: rgba(255,255,255,.7); padding: 48px 0 24px; margin-top: 64px; }
.footer-grid  { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-brand .logo-text { color: #fff; }
.footer-brand p { margin-top: 12px; font-size: 14px; max-width: 260px; }
.footer-links h4 { color: #fff; font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 12px; }
.footer-links ul { list-style: none; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: rgba(255,255,255,.65); font-size: 14px; text-decoration: none; }
.footer-links a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 20px; font-size: 13px; }

/* ─── Nav CTA ────────────────────────────────────────────────────────────────── */
.nav-cta { margin-left: auto; background: var(--blue); color: #fff !important; padding: 7px 16px !important; border-radius: var(--radius); font-size: 13px; font-weight: 600 !important; transition: background .15s; }
.nav-cta:hover { background: #1e40af !important; text-decoration: none !important; }

/* ─── Hero — product homepage ─────────────────────────────────────────────────── */
.hero-product    { background: var(--navy); color: #fff; padding: 80px 0 64px; }
.hero-product h1 { font-size: 46px; font-weight: 700; line-height: 1.15; max-width: 680px; }
.hero-product h1 em { color: #60a5fa; font-style: normal; }
.hero-product p  { font-size: 18px; color: rgba(255,255,255,.72); margin-top: 18px; max-width: 560px; line-height: 1.65; }
.hero-actions    { display: flex; gap: 12px; margin-top: 36px; flex-wrap: wrap; }
.btn-hero-primary  { height: 48px; padding: 0 28px; background: var(--blue); color: #fff; border: none; border-radius: var(--radius); font-size: 15px; font-weight: 600; cursor: pointer; transition: background .15s; font-family: inherit; text-decoration: none; display: inline-flex; align-items: center; }
.btn-hero-primary:hover { background: #1e40af; text-decoration: none; color: #fff; }
.btn-hero-ghost   { height: 48px; padding: 0 24px; background: transparent; color: rgba(255,255,255,.85); border: 1px solid rgba(255,255,255,.3); border-radius: var(--radius); font-size: 15px; font-weight: 500; cursor: pointer; transition: all .15s; font-family: inherit; text-decoration: none; display: inline-flex; align-items: center; }
.btn-hero-ghost:hover { border-color: rgba(255,255,255,.7); color: #fff; text-decoration: none; }

/* ─── Stats bar ──────────────────────────────────────────────────────────────── */
.stats-bar       { background: #1a3358; border-top: 1px solid rgba(255,255,255,.08); }
.stats-bar .container { display: flex; gap: 0; }
.stat-pill       { padding: 18px 28px; border-right: 1px solid rgba(255,255,255,.08); flex: 1; text-align: center; }
.stat-pill:last-child { border-right: none; }
.stat-pill .num  { font-size: 26px; font-weight: 700; color: #fff; line-height: 1; }
.stat-pill .lbl  { font-size: 12px; color: rgba(255,255,255,.5); margin-top: 4px; text-transform: uppercase; letter-spacing: .06em; font-weight: 500; }

/* ─── Section ────────────────────────────────────────────────────────────────── */
.section         { padding: 72px 0; }
.section-alt     { background: #fff; }
.section-dark    { background: var(--navy); color: #fff; }
.section-label-sm { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); margin-bottom: 12px; }
.section h2      { font-size: 32px; font-weight: 700; color: var(--navy); line-height: 1.25; }
.section-alt h2, .section-dark h2 { color: inherit; }
.section-dark h2 { color: #fff; }
.section-sub     { font-size: 17px; color: var(--muted); margin-top: 12px; max-width: 600px; line-height: 1.65; }
.section-dark .section-sub { color: rgba(255,255,255,.65); }

/* ─── Feature cards ──────────────────────────────────────────────────────────── */
.features-grid   { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin-top: 48px; }
.feature-card    { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 28px; box-shadow: var(--shadow); position: relative; transition: box-shadow .2s; }
.feature-card:hover { box-shadow: var(--shadow-md); }
.feature-card.dimmed { opacity: .75; }
.feature-icon    { width: 44px; height: 44px; border-radius: 10px; background: #eff6ff; display: flex; align-items: center; justify-content: center; margin-bottom: 16px; font-size: 20px; }
.feature-card h3 { font-size: 17px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.feature-card p  { font-size: 14px; color: var(--muted); line-height: 1.65; }
.coming-soon-tag { display: inline-block; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; background: #fef3c7; color: #92400e; padding: 2px 8px; border-radius: 99px; margin-bottom: 12px; }
.live-tag        { display: inline-block; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; background: #d1fae5; color: #065f46; padding: 2px 8px; border-radius: 99px; margin-bottom: 12px; }

/* ─── Use-case cards ─────────────────────────────────────────────────────────── */
.use-cases-grid  { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin-top: 40px; }
.use-case-card   { background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1); border-radius: 8px; padding: 24px; }
.use-case-card h3 { font-size: 16px; font-weight: 700; color: #fff; margin-bottom: 8px; }
.use-case-card p  { font-size: 14px; color: rgba(255,255,255,.6); line-height: 1.65; }
.use-case-icon   { font-size: 28px; margin-bottom: 12px; }

/* ─── Jurisdiction cards — case-centric ──────────────────────────────────────── */
.jur-cards-lg    { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; margin-top: 40px; }
.jur-card-lg     { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 22px 24px; box-shadow: var(--shadow); transition: box-shadow .2s, transform .2s; text-decoration: none; display: block; }
.jur-card-lg:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); text-decoration: none; }
.jur-card-lg .flag { font-size: 30px; }
.jur-card-lg h3  { font-size: 16px; font-weight: 700; color: var(--navy); margin: 8px 0 4px; }
.jur-card-lg .case-count { font-size: 22px; font-weight: 700; color: var(--blue); line-height: 1; margin-bottom: 2px; }
.jur-card-lg .case-lbl   { font-size: 12px; color: var(--muted); }
.jur-card-lg .dir-link   { font-size: 12px; color: var(--muted); margin-top: 12px; border-top: 1px solid var(--border); padding-top: 10px; }
.jur-card-lg .dir-link a { color: var(--blue); }

/* ─── CTA section ─────────────────────────────────────────────────────────────── */
.cta-section     { background: linear-gradient(135deg, #1d4ed8 0%, #0d1f3c 100%); color: #fff; padding: 80px 0; text-align: center; }
.cta-section h2  { font-size: 34px; font-weight: 700; }
.cta-section p   { font-size: 17px; color: rgba(255,255,255,.75); margin-top: 12px; max-width: 500px; margin-left: auto; margin-right: auto; }
.email-capture   { display: flex; gap: 10px; max-width: 440px; margin: 32px auto 0; }
.email-capture input { flex: 1; height: 46px; border: none; border-radius: var(--radius); padding: 0 16px; font-size: 15px; font-family: inherit; }
.email-capture button { height: 46px; padding: 0 24px; background: #fff; color: var(--blue); border: none; border-radius: var(--radius); font-size: 15px; font-weight: 700; cursor: pointer; font-family: inherit; white-space: nowrap; }
.email-capture button:hover { background: #eff6ff; }

/* ─── Pricing ────────────────────────────────────────────────────────────────── */
.pricing-grid    { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin-top: 48px; max-width: 900px; margin-left: auto; margin-right: auto; }
.pricing-card    { background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 32px; box-shadow: var(--shadow); position: relative; }
.pricing-card.featured { border-color: var(--blue); box-shadow: 0 0 0 2px var(--blue), var(--shadow-md); }
.pricing-card .plan-name { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.pricing-card .price-val { font-size: 40px; font-weight: 700; color: var(--navy); line-height: 1; margin: 8px 0 4px; }
.pricing-card .price-val span { font-size: 18px; font-weight: 500; color: var(--muted); }
.pricing-card .price-note { font-size: 13px; color: var(--muted); margin-bottom: 24px; }
.pricing-card ul { list-style: none; font-size: 14px; margin-bottom: 28px; }
.pricing-card ul li { padding: 7px 0; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 8px; }
.pricing-card ul li:last-child { border-bottom: none; }
.pricing-card ul li .chk  { color: var(--green); font-weight: 700; }
.pricing-card ul li .lock { color: var(--muted); font-size: 12px; }
.pricing-popular { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--blue); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 3px 14px; border-radius: 99px; white-space: nowrap; }

/* ─── About / data sources ────────────────────────────────────────────────────── */
.sources-grid    { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; margin-top: 40px; }
.source-card     { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 20px; text-align: center; }
.source-card .flag { font-size: 32px; margin-bottom: 10px; }
.source-card h4  { font-size: 14px; font-weight: 700; color: var(--navy); margin-bottom: 4px; }
.source-card p   { font-size: 12px; color: var(--muted); line-height: 1.5; }
.source-card .licence { display: inline-block; font-size: 10px; font-weight: 600; padding: 2px 8px; background: #d1fae5; color: #065f46; border-radius: 99px; margin-top: 8px; }

/* ─── Inline breadcrumb ────────────────────────────────────────────────────────── */
.breadcrumb { font-size: 13px; color: var(--muted); margin-bottom: 20px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--blue); }
.breadcrumb span { margin: 0 6px; }

/* ─── Page hero (non-product pages) ─────────────────────────────────────────── */
.page-hero       { background: var(--navy); color: #fff; padding: 56px 0 48px; }
.page-hero h1    { font-size: 36px; font-weight: 700; }
.page-hero p     { font-size: 16px; color: rgba(255,255,255,.7); margin-top: 12px; max-width: 560px; }

/* ─── Responsive ─────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .main-nav { display: none; }
  .data-table thead { display: none; }
  .data-table tbody tr { display: block; padding: 12px 0; }
  .data-table td { display: block; padding: 4px 16px; }
  .data-table td::before { content: attr(data-label); font-size: 11px; color: var(--muted); text-transform: uppercase; display: block; }
  .hero h1 { font-size: 28px; }
}
