:root{

  --bg:#0F172A; --surface:#1E293B; --surface2:#273449; --surface3:#334155;
  --border:rgba(248,250,252,0.10); --border2:rgba(248,250,252,0.18);
  --hover-overlay:rgba(248,250,252,0.06); --divider:rgba(248,250,252,0.08);
  --accent:#3B82F6; --accent-hover:#2563EB; --accent-dark:#1D4ED8; --accent2:#1D4ED8; --accent-contrast:#FFFFFF;
  --heading:#F8FAFC; --text:#E2E8F0; --muted:#94A3B8;
  --success:#22C55E; --warning:#F59E0B; --danger:#EF4444; --info:#3B82F6;
  --shadow-sm:0 1px 2px rgba(0,0,0,.35); --shadow-md:0 12px 34px rgba(0,0,0,.45);
  --shadow-glow:0 0 60px rgba(59,130,246,.22);
  --radius:14px; --radius-sm:9px; --radius-lg:22px;
  --font-display:'Space Grotesk',sans-serif; --font-body:'Plus Jakarta Sans',sans-serif; --font-mono:'JetBrains Mono',monospace;
  --maxw:1080px;

  --viz-canvas:#0B1120; --viz-inset:#0E1626; --viz-line:#26324a;
  --w-hi:#F87171;  --w-mid:#FBBF24;  --w-lo:#60A5FA;  --w-min:#94A3B8;
  --cat-company:#A78BFA; --cat-tech:#38BDF8; --cat-agri:#FBBF24; --cat-theory:#F87171; --cat-place:#34D399; --cat-general:#94A3B8;
  --doc-a:#38BDF8; --doc-b:#FBBF24; --mark-query:#FB7185; --mark-match:#34D399;
}
:root[data-theme="light"]{
  --bg:#F4F5F7; --surface:#FFFFFF; --surface2:#FAFAFB; --surface3:#EEF0F3;
  --border:#D1D5DB; --border2:#B8BEC9;
  --hover-overlay:rgba(17,24,39,0.05); --divider:rgba(17,24,39,0.08);
  --accent:#3B82F6; --accent-hover:#2563EB; --accent-dark:#1D4ED8; --accent2:#1D4ED8; --accent-contrast:#FFFFFF;
  --heading:#111827; --text:#374151; --muted:#6B7280;
  --success:#16A34A; --warning:#B45309; --danger:#DC2626; --info:#2563EB;
  --shadow-sm:0 1px 2px rgba(17,24,39,.06); --shadow-md:0 10px 30px rgba(17,24,39,.10); --shadow-glow:0 0 60px rgba(59,130,246,.14);

  --viz-canvas:#F1F5F9; --viz-inset:#E9EEF5; --viz-line:#CBD5E1;
  --w-hi:#DC2626;  --w-mid:#B45309;  --w-lo:#2563EB;  --w-min:#64748B;
  --cat-company:#7C3AED; --cat-tech:#0284C7; --cat-agri:#B45309; --cat-theory:#DC2626; --cat-place:#0D9488; --cat-general:#64748B;
  --doc-a:#0284C7; --doc-b:#B45309; --mark-query:#E11D48; --mark-match:#059669;
}
html{color-scheme:dark;} html[data-theme="light"]{color-scheme:light;}

*{box-sizing:border-box;}
[hidden]{display:none !important;}
html{scroll-behavior:smooth;}
body{
  margin:0; font-family:var(--font-body); background:var(--bg); color:var(--text);
  font-weight:500; line-height:1.55; min-height:100vh;
  -webkit-font-smoothing:antialiased; overflow-x:hidden;
}
a{color:inherit;}
:focus-visible{outline:2px solid var(--accent); outline-offset:2px; border-radius:4px;}

.hero-title,.section-title,.topics-title,.card h3,.steps h3,.topic h4,.guide h1,.guide h2,.faq summary,.field-head label,.saved-title,.sh-wordmark{color:var(--heading);}
.ic{width:1.05em; height:1.05em; stroke:currentColor; fill:none; stroke-width:2; stroke-linecap:round; stroke-linejoin:round; vertical-align:-0.16em; display:inline-block; flex-shrink:0;}
.ic-fill{fill:currentColor; stroke:none;}

.site-header{
  position:sticky; top:0; z-index:20;
  background:color-mix(in srgb,var(--bg) 82%,transparent); backdrop-filter:blur(12px);
  border-bottom:1px solid var(--border);
}
.nav{
  display:flex; align-items:center; justify-content:space-between; gap:1rem;
  max-width:var(--maxw); margin:0 auto; padding:1.1rem 1.25rem;
  position:relative;
}
.sh-brand{display:inline-flex; align-items:center; gap:.6rem; text-decoration:none; color:inherit;
  font-family:var(--font-display); font-weight:700; font-size:1.15rem; letter-spacing:-.02em;}
.sh-logo{height:34px; width:auto; display:block; flex-shrink:0;}
.sh-wordmark{white-space:nowrap;}
.sh-accent{color:var(--accent);}
.nav-pills{
  display:flex; align-items:center; gap:.2rem;
  background:var(--surface2); border:1px solid var(--border);
  padding:.28rem; border-radius:999px;
}
.pill{
  display:inline-flex; align-items:center; gap:.35rem;
  text-decoration:none; color:var(--muted); font-weight:600; font-size:.88rem; line-height:1;
  padding:.45rem .8rem; border-radius:999px; white-space:nowrap;
  transition:color .15s, background .15s;
}
.pill:hover{color:var(--text); background:var(--hover-overlay);}
.pill .ic{width:1em; height:1em;}
.pill-ext{color:var(--accent);}
.pill-ext:hover{color:var(--accent); background:color-mix(in srgb,var(--accent) 12%,transparent);}
.nav-actions{display:flex; align-items:center; gap:.5rem;}
.icon-btn.menu-btn{display:none;}
.menu-btn .ic-close{display:none;}
.menu-btn[aria-expanded="true"] .ic-menu{display:none;}
.menu-btn[aria-expanded="true"] .ic-close{display:inline-block;}
.icon-btn{
  display:grid; place-items:center; width:38px; height:38px; border-radius:10px; cursor:pointer;
  background:var(--surface2); color:var(--text); border:1px solid var(--border); font-size:1.05rem; transition:background .15s,border-color .15s;
}
.icon-btn:hover{background:var(--surface3); border-color:var(--border2);}
.ic-moon{display:none;} :root[data-theme="light"] .ic-sun{display:none;} :root[data-theme="light"] .ic-moon{display:inline-block;}

.sh-breadcrumb{max-width:var(--maxw); margin:0 auto; padding:.9rem 1.25rem 0;}
.sh-breadcrumb ol{list-style:none; display:flex; flex-wrap:wrap; align-items:center; gap:.15rem; margin:0; padding:0; font-size:.82rem; color:var(--muted);}
.sh-breadcrumb li{display:inline-flex; align-items:center; gap:.15rem; min-width:0;}
.sh-breadcrumb a{text-decoration:none; color:var(--muted); font-weight:600; padding:.15rem .1rem; transition:color .15s;}
.sh-breadcrumb a:hover{color:var(--text);}
.sh-breadcrumb li[aria-current="page"]{color:var(--text); font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:60vw;}
.sh-breadcrumb .sh-sep{color:var(--border2); padding:0 .1rem; user-select:none;}

.hero{max-width:var(--maxw); margin:0 auto; padding:1.5rem 1.25rem 1rem;}
.hero-inner{text-align:center; max-width:720px; margin:0 auto 1.25rem;}
.hero-badge{
  display:inline-flex; align-items:center; gap:.45rem; font-size:.78rem; font-weight:600; color:var(--accent);
  background:color-mix(in srgb,var(--accent) 12%,transparent); border:1px solid color-mix(in srgb,var(--accent) 30%,transparent);
  padding:.28rem .7rem; border-radius:999px; margin-bottom:.7rem;
}
.hero-title{font-family:var(--font-display); font-weight:700; font-size:clamp(1.8rem,4.2vw,2.6rem); line-height:1.1; letter-spacing:-.03em; margin:0 0 .5rem;}
.grad{background:linear-gradient(120deg,var(--accent),var(--accent2)); -webkit-background-clip:text; background-clip:text; color:transparent;}
.hero-sub{font-size:clamp(.92rem,1.6vw,1.02rem); color:var(--muted); margin:0 auto; max-width:600px;}

.tool{
  background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-lg);
  box-shadow:var(--shadow-md); padding:1.1rem; max-width:1040px; margin:0 auto;
  display:flex; flex-direction:column;
}
@media(min-width:640px){ .tool{padding:1.3rem 1.4rem 1.5rem;} }

.notice{
  display:flex; align-items:flex-start; gap:.7rem; font-size:.9rem;
  color:var(--info); background:color-mix(in srgb,var(--info) 10%,transparent);
  border:1px solid color-mix(in srgb,var(--info) 28%,transparent);
  border-radius:var(--radius-sm); padding:.75rem .9rem; margin-bottom:1.1rem;
}
.notice .ic{margin-top:.1rem; flex-shrink:0;}
.notice-body{flex-grow:1; color:var(--text);}
.notice-close{background:none; border:none; color:var(--muted); cursor:pointer; padding:.15rem; border-radius:6px; display:grid; place-items:center;}
.notice-close:hover{background:var(--hover-overlay); color:var(--text);}

.field-head{display:flex; align-items:center; justify-content:space-between; margin-bottom:.5rem;}
.field-head label{font-weight:600; font-size:.95rem;}
.count{font-family:var(--font-mono); font-size:.82rem; color:var(--muted); background:var(--surface2); padding:.2rem .55rem; border-radius:999px; border:1px solid var(--border);}
textarea, input[type="text"], input[type="number"], select{
  width:100%; font-family:var(--font-body); font-size:.95rem; color:var(--text);
  background:var(--surface2); border:1.5px solid var(--border); border-radius:var(--radius-sm);
  padding:.8rem .9rem; transition:border-color .15s, box-shadow .15s;
}
textarea{resize:vertical; min-height:150px; font-family:var(--font-mono); font-size:.9rem; line-height:1.6;}
textarea::placeholder{color:var(--muted); opacity:.7;}
textarea:focus, input:focus, select:focus{outline:none; border-color:var(--accent); box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 22%,transparent);}
select{cursor:pointer;}

.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:.5rem; cursor:pointer;
  font-family:var(--font-body); font-weight:700; font-size:.95rem; padding:.8rem 1rem;
  border-radius:var(--radius-sm); border:1px solid transparent; transition:transform .12s, background .15s, border-color .15s, opacity .15s;
}
.btn:active{transform:translateY(1px);}
.btn:disabled{opacity:.5; cursor:not-allowed;}
.btn-sm{padding:.6rem .85rem; font-size:.88rem;}
.btn-primary{background:linear-gradient(135deg,var(--accent),var(--accent2)); color:#fff; box-shadow:var(--shadow-glow);}
.btn-primary:hover{filter:brightness(1.07);}
.btn-secondary{background:var(--surface2); color:var(--text); border-color:var(--border2);}
.btn-secondary:hover{background:var(--surface3);}
.btn-ghost{background:transparent; color:var(--muted); border-color:var(--border);}
.btn-ghost:hover{color:var(--text); background:var(--hover-overlay);}

.section{max-width:var(--maxw); margin:0 auto; padding:3.5rem 1.25rem;}
.section-alt{background:var(--surface); border-top:1px solid var(--border); border-bottom:1px solid var(--border); max-width:none;}
.section-alt > *{max-width:var(--maxw); margin-left:auto; margin-right:auto;}
.section-title{font-family:var(--font-display); font-weight:700; font-size:clamp(1.5rem,3.5vw,2.1rem); letter-spacing:-.02em; text-align:center; margin:0 auto 2.2rem; max-width:640px; line-height:1.2;}

.grid{display:grid; grid-template-columns:repeat(3,1fr); gap:1.1rem;}
@media(max-width:860px){ .grid{grid-template-columns:repeat(2,1fr);} }
@media(max-width:560px){ .grid{grid-template-columns:1fr;} }
.card{background:var(--surface); border:1px solid var(--border); border-radius:var(--radius); padding:1.5rem; transition:transform .15s, border-color .15s;}
.section-alt .card{background:var(--surface2);}
.card:hover{transform:translateY(-3px); border-color:var(--border2);}
.card-icon{display:grid; place-items:center; width:44px; height:44px; border-radius:12px; font-size:1.2rem; color:#fff; background:linear-gradient(135deg,var(--accent),var(--accent2)); margin-bottom:1rem;}
.card h3{font-family:var(--font-display); font-size:1.15rem; font-weight:600; margin:0 0 .5rem;}
.card p{color:var(--muted); font-size:.95rem; margin:0;}

.steps{list-style:none; counter-reset:s; margin:0 auto; padding:0; max-width:900px; display:grid; grid-template-columns:repeat(3,1fr); gap:1.5rem;}
@media(max-width:760px){ .steps{grid-template-columns:1fr; gap:1.1rem; max-width:460px;} }
.steps li{display:flex; gap:1rem; align-items:flex-start;}
.step-num{flex-shrink:0; display:grid; place-items:center; width:38px; height:38px; border-radius:50%; font-family:var(--font-display); font-weight:700; color:#fff; background:linear-gradient(135deg,var(--accent),var(--accent2));}
.steps h3{font-family:var(--font-display); font-size:1.1rem; margin:.2rem 0 .4rem;}
.steps p{color:var(--muted); font-size:.93rem; margin:0;}
.steps code, .card code, .faq code{font-family:var(--font-mono); font-size:.85em; background:var(--surface3); padding:.05rem .35rem; border-radius:5px;}

.topics-title{font-family:var(--font-display); font-weight:600; font-size:1.25rem; text-align:center; margin:3rem auto 1.6rem; padding-top:2rem; border-top:1px solid var(--divider); max-width:900px;}
.topic-grid{max-width:900px; margin:0 auto; display:grid; grid-template-columns:repeat(2,1fr); gap:1.1rem;}
@media(max-width:680px){ .topic-grid{grid-template-columns:1fr;} }
.topic{background:var(--surface2); border:1px solid var(--border); border-radius:var(--radius); padding:1.3rem 1.4rem;}
.topic h4{display:flex; align-items:center; gap:.5rem; font-family:var(--font-display); font-size:1.05rem; font-weight:600; margin:0 0 .5rem;}
.topic h4 .ic{color:var(--accent);}
.topic p{color:var(--muted); font-size:.92rem; margin:0;}
.topic strong{color:var(--text); font-weight:600;}
.topic code{font-family:var(--font-mono); font-size:.85em; background:var(--surface3); padding:.05rem .35rem; border-radius:5px;}

.faq{max-width:720px; margin:0 auto; display:flex; flex-direction:column; gap:.7rem;}
.faq details{background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.2rem;}
.section:not(.section-alt) .faq details{background:var(--surface);}
.faq summary{cursor:pointer; font-weight:600; padding:.9rem 1rem; list-style:none; display:flex; justify-content:space-between; align-items:center; gap:1rem;}
.faq summary::-webkit-details-marker{display:none;}
.faq summary::after{content:"+"; font-family:var(--font-mono); font-size:1.3rem; color:var(--accent); transition:transform .2s;}
.faq details[open] summary::after{transform:rotate(45deg);}
.faq p{color:var(--muted); margin:0; padding:0 1rem 1rem; font-size:.94rem;}

.site-footer{border-top:1px solid var(--border); margin-top:2rem; padding:3rem 1.25rem 1.6rem; background:var(--surface);}
.footer-inner{max-width:var(--maxw); margin:0 auto; display:grid; grid-template-columns:1.7fr 1fr 1fr 1fr 1.1fr; gap:2rem;}
.footer-brand-col{display:flex; flex-direction:column; gap:.9rem; max-width:320px;}
.footer-pitch{color:var(--muted); font-size:.87rem; margin:0; line-height:1.5;}
.social{display:flex; gap:.5rem; flex-wrap:wrap;}
.social a{
  display:grid; place-items:center; width:34px; height:34px; border-radius:9px;
  color:var(--muted); background:var(--surface2); border:1px solid var(--border);
  transition:color .15s, border-color .15s, background .15s;
}
.social a:hover{color:var(--accent); border-color:var(--accent); background:color-mix(in srgb,var(--accent) 10%,transparent);}
.social .ic{width:1.05rem; height:1.05rem;}
.footer-col h3{font-family:var(--font-display); font-size:.95rem; font-weight:600; margin:0 0 .8rem; color:var(--heading);}
.footer-col ul{list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:.55rem;}
.footer-col a{text-decoration:none; color:var(--muted); font-size:.9rem; font-weight:500; transition:color .15s;}
.footer-col a:hover{color:var(--accent);}
.footer-bottom{
  max-width:var(--maxw); margin:2.4rem auto 0; padding-top:1.4rem; border-top:1px solid var(--divider);
  display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.5rem 1.5rem;
  color:var(--muted); font-size:.83rem;
}
.footer-bottom p{margin:0;}
.footer-bottom a{color:var(--muted); text-decoration:none; font-weight:600;}
.footer-bottom a:hover{color:var(--accent);}
@media(max-width:860px){ .footer-inner{grid-template-columns:1fr 1fr; gap:2rem 1.5rem;} .footer-brand-col{grid-column:1/-1; max-width:none;} }

.install-card{
  position:fixed; right:1.1rem; bottom:1.1rem; z-index:45;
  width:min(340px, calc(100vw - 2.2rem));
  background:var(--surface); border:1px solid var(--border); border-radius:var(--radius);
  box-shadow:var(--shadow-md); padding:1rem; animation:fabin .3s ease;
}
.install-card-head{display:flex; align-items:center; gap:.6rem; margin-bottom:.5rem; padding-right:1.4rem;}
.install-card-logo{height:26px; width:auto; display:block; flex-shrink:0;}
.install-card-title{font-family:var(--font-display); font-weight:700; font-size:.98rem; color:var(--heading);}
.install-card p{margin:0 0 .9rem; color:var(--muted); font-size:.87rem; line-height:1.45;}
.install-card-actions{display:flex; gap:.5rem;}
.install-card-actions .btn{flex:1;}
.install-card-close{
  position:absolute; top:.5rem; right:.5rem; background:none; border:none; color:var(--muted);
  cursor:pointer; padding:.25rem; border-radius:6px; display:grid; place-items:center;
}
.install-card-close:hover{background:var(--hover-overlay); color:var(--text);}
@media(max-width:560px){ .install-card{left:1.1rem; right:1.1rem; width:auto;} }

.install-fab{
  position:fixed; right:1.1rem; bottom:1.1rem; z-index:40;
  display:inline-flex; align-items:center; gap:.5rem; cursor:pointer;
  font-family:var(--font-body); font-weight:700; font-size:.92rem; color:#fff;
  background:linear-gradient(135deg,var(--accent),var(--accent2)); border:none;
  padding:.75rem 1.1rem; border-radius:999px; box-shadow:var(--shadow-md);
  animation:fabin .3s ease;
}
@keyframes fabin{from{opacity:0; transform:translateY(10px);} to{opacity:1; transform:none;}}
.install-fab:hover{filter:brightness(1.08);}
.offline-badge{
  position:fixed; left:1.1rem; bottom:1.1rem; z-index:40;
  display:inline-flex; align-items:center; gap:.4rem; font-size:.82rem; font-weight:600;
  color:var(--warning); background:var(--surface); border:1px solid color-mix(in srgb,var(--warning) 40%,transparent);
  padding:.5rem .8rem; border-radius:999px; box-shadow:var(--shadow-sm);
}
.toast{
  position:fixed; left:50%; bottom:1.4rem; transform:translateX(-50%);
  z-index:50; background:var(--text); color:var(--bg); font-weight:600; font-size:.9rem;
  padding:.7rem 1.1rem; border-radius:999px; box-shadow:var(--shadow-md);
  display:inline-flex; align-items:center; gap:.5rem; animation:toastin .25s ease;
}
@keyframes toastin{from{opacity:0; transform:translate(-50%,10px);} to{opacity:1; transform:translate(-50%,0);}}
.toast.err{background:var(--danger); color:#fff;}

@media(max-width:760px){
  .icon-btn.menu-btn{display:grid;}
  .nav-pills{
    display:none; position:absolute; top:calc(100% + .5rem); left:1.25rem; right:1.25rem;
    flex-direction:column; align-items:stretch; gap:.15rem;
    background:var(--surface); border:1px solid var(--border); border-radius:var(--radius);
    padding:.5rem; box-shadow:var(--shadow-md); z-index:30;
  }
  .nav-pills.open{display:flex;}
  .pill{justify-content:flex-start; padding:.7rem .85rem; font-size:.95rem; border-radius:var(--radius-sm);}
  .sh-breadcrumb ol{justify-content:center;}
}
@media(max-width:640px){
  .hero{padding-top:1.6rem;}
  .footer-inner{grid-template-columns:1fr; gap:2rem; text-align:center; justify-items:center;}
  .footer-brand-col{align-items:center; max-width:340px;}
  .social{justify-content:center;}
  .footer-col ul{align-items:center;}
  .footer-bottom{flex-direction:column; justify-content:center; text-align:center; gap:.5rem;}
}
@media (prefers-reduced-motion: reduce){
  *{animation-duration:.001ms !important; transition-duration:.001ms !important; scroll-behavior:auto !important;}
}

.fc{display:flex; flex-direction:column; gap:1rem; width:100%;}
.fc-mono{font-family:var(--font-mono);}
.fc-eyebrow{font-family:var(--font-mono); font-size:.62rem; letter-spacing:.16em; text-transform:uppercase; color:var(--muted); font-weight:700;}

.fc-modes{display:flex; gap:.35rem; background:var(--surface2); border:1px solid var(--border); border-radius:999px; padding:.28rem; align-self:flex-start; flex-wrap:wrap;}
.fc-mode-btn{
  display:inline-flex; align-items:center; gap:.4rem; border:none; cursor:pointer;
  background:transparent; color:var(--muted); font-family:var(--font-body); font-weight:700;
  font-size:.82rem; padding:.5rem .95rem; border-radius:999px; transition:background .15s,color .15s;
}
.fc-mode-btn:hover{color:var(--text);}
.fc-mode-btn[aria-selected="true"]{background:linear-gradient(135deg,var(--accent),var(--accent2)); color:#fff;}

.fc-header{background:var(--surface2); border:1px solid var(--border); border-radius:var(--radius); padding:.85rem; display:flex; flex-direction:column; gap:.8rem;}
.fc-metrics{display:grid; grid-template-columns:repeat(4,1fr); gap:.5rem;}
.fc-metric{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.5rem .6rem; text-align:left;}
.fc-metric .k{font-family:var(--font-mono); font-size:.58rem; letter-spacing:.1em; text-transform:uppercase; color:var(--muted); display:block;}
.fc-metric .v{font-family:var(--font-mono); font-size:1.05rem; font-weight:700; color:var(--heading);}
.fc-metric.a .v{color:var(--accent);} .fc-metric.b .v{color:var(--mark-match);} .fc-metric.c .v{color:var(--warning);} .fc-metric.d .v{color:var(--mark-query);}

.fc-steps{display:grid; grid-template-columns:repeat(4,1fr); gap:.5rem;}
.fc-step{
  display:flex; align-items:center; gap:.6rem; text-align:left; cursor:pointer;
  background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-sm);
  padding:.55rem .6rem; transition:border-color .15s, background .15s;
}
.fc-step:hover{border-color:var(--border2);}
.fc-step[aria-current="true"]{border-color:var(--accent); background:color-mix(in srgb,var(--accent) 10%,transparent);}
.fc-step-num{flex-shrink:0; display:grid; place-items:center; width:26px; height:26px; border-radius:50%; font-family:var(--font-mono); font-size:.72rem; font-weight:700; background:var(--viz-canvas); color:var(--muted); border:1px solid var(--border);}
.fc-step[aria-current="true"] .fc-step-num{background:linear-gradient(135deg,var(--accent),var(--accent2)); color:#fff; border-color:transparent;}
.fc-step.done .fc-step-num{color:var(--mark-match); border-color:color-mix(in srgb,var(--mark-match) 45%,transparent);}
.fc-step-txt{min-width:0;}
.fc-step-txt .s{display:block; font-family:var(--font-mono); font-size:.56rem; letter-spacing:.1em; text-transform:uppercase; color:var(--muted);}
.fc-step-txt .n{display:block; font-size:.8rem; font-weight:700; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis;}
.fc-step[aria-current="true"] .fc-step-txt .n{color:var(--heading);}

.fc-controls{display:flex; align-items:center; justify-content:space-between; gap:.6rem;}
.fc-nav{display:flex; align-items:center; gap:.5rem; font-family:var(--font-mono); font-size:.78rem; color:var(--muted);}
.fc-navbtn{display:grid; place-items:center; width:30px; height:30px; border-radius:8px; background:var(--surface); border:1px solid var(--border); color:var(--text); cursor:pointer;}
.fc-navbtn:hover{background:var(--surface3);}
.fc-navbtn:disabled{opacity:.35; cursor:not-allowed;}

.fc-panel{background:var(--surface2); border:1px solid var(--border); border-radius:var(--radius); padding:1rem; display:flex; flex-direction:column; gap:.75rem; min-width:0;}
.fc-panel-head{display:flex; align-items:center; gap:.5rem; padding-bottom:.6rem; border-bottom:1px solid var(--divider);}
.fc-panel-head .ic{color:var(--accent);}
.fc-panel-title{font-family:var(--font-mono); font-size:.72rem; letter-spacing:.12em; text-transform:uppercase; font-weight:700; color:var(--heading);}
.fc-panel-head .fc-tools{margin-left:auto; display:flex; align-items:center; gap:.3rem;}
.fc-hint{font-family:var(--font-mono); font-size:.72rem; color:var(--muted); line-height:1.5; margin:0;}
.fc-iconbtn{display:grid; place-items:center; width:28px; height:28px; border-radius:7px; background:var(--surface); border:1px solid var(--border); color:var(--muted); cursor:pointer;}
.fc-iconbtn:hover{color:var(--text); background:var(--surface3);}
.fc-chip{font-family:var(--font-mono); font-size:.68rem; font-weight:700; padding:.2rem .5rem; border-radius:6px; border:1px solid var(--border); background:var(--surface); color:var(--accent); cursor:pointer;}
.fc-chip:hover{border-color:var(--accent);}

.fc-2col{display:grid; grid-template-columns:5fr 7fr; gap:1rem;}
.fc-2col.rev{grid-template-columns:7fr 5fr;}
@media(max-width:820px){ .fc-2col,.fc-2col.rev{grid-template-columns:1fr;} }

.fc-canvas{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm);}

.fc-code{font-family:var(--font-mono); font-size:.78rem; line-height:1.55; min-height:260px; background:var(--viz-canvas);}
.fc-drop{position:relative; border-radius:var(--radius-sm); transition:box-shadow .15s;}
.fc-drop.drag{box-shadow:0 0 0 2px var(--accent);}

.fc-tabs{display:inline-flex; gap:.2rem; background:var(--surface); border:1px solid var(--border); border-radius:999px; padding:.2rem;}
.fc-tab{border:none; background:transparent; cursor:pointer; font-family:var(--font-mono); font-size:.7rem; font-weight:700; color:var(--muted); padding:.35rem .7rem; border-radius:999px;}
.fc-tab[aria-selected="true"]{background:var(--surface3); color:var(--heading);}
.fc-legend{display:flex; flex-wrap:wrap; gap:.7rem; font-family:var(--font-mono); font-size:.68rem; color:var(--muted); align-items:center;}
.fc-legend .sw{width:10px; height:10px; border-radius:3px; display:inline-block; vertical-align:-1px; margin-right:.3rem;}
.fc-scroll{overflow:auto; max-height:430px;}
.fc-nodes{display:flex; flex-direction:column; gap:.6rem;}
.fc-node{border:1px solid var(--border); border-left-width:3px; border-radius:var(--radius-sm); padding:.7rem .8rem; background:var(--surface); cursor:default;}
.fc-node .fc-node-top{display:flex; align-items:center; justify-content:space-between; margin-bottom:.4rem; gap:.5rem;}
.fc-node .fc-node-tag{font-family:var(--font-mono); font-size:.64rem; font-weight:700; text-transform:uppercase; letter-spacing:.08em; padding:.12rem .45rem; border-radius:5px; border:1px solid var(--border);}
.fc-node .fc-node-w{font-family:var(--font-mono); font-size:.72rem; font-weight:700;}
.fc-node .fc-node-text{font-size:.86rem; color:var(--text); line-height:1.5;}
.fc-node.w-hi{border-left-color:var(--w-hi);}   .fc-node.w-hi .fc-node-tag,.fc-node.w-hi .fc-node-w{color:var(--w-hi);}
.fc-node.w-mid{border-left-color:var(--w-mid);} .fc-node.w-mid .fc-node-tag,.fc-node.w-mid .fc-node-w{color:var(--w-mid);}
.fc-node.w-lo{border-left-color:var(--w-lo);}   .fc-node.w-lo .fc-node-tag,.fc-node.w-lo .fc-node-w{color:var(--w-lo);}
.fc-node.w-min{border-left-color:var(--w-min);} .fc-node.w-min .fc-node-tag,.fc-node.w-min .fc-node-w{color:var(--w-min);}

.fc-tree{font-family:var(--font-mono); font-size:.76rem; display:flex; flex-direction:column;}
.fc-tree-root{color:var(--accent); font-weight:700; margin-bottom:.4rem;}
.fc-tree-branch{border-left:1px solid var(--border); padding-left:.9rem; display:flex; flex-direction:column; gap:.1rem;}
.fc-tree-row{display:flex; gap:.7rem; padding:.4rem .3rem; border-bottom:1px solid var(--divider); align-items:baseline;}
.fc-tree-row:hover{background:var(--hover-overlay);}
.fc-tree-tag{flex-shrink:0; width:5.5rem; font-weight:700;}
.fc-tree-tag.w-hi{color:var(--w-hi);} .fc-tree-tag.w-mid{color:var(--w-mid);} .fc-tree-tag.w-lo{color:var(--w-lo);} .fc-tree-tag.w-min{color:var(--w-min);}
.fc-tree-body{min-width:0;}
.fc-tree-body .t{color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis;}
.fc-tree-body .m{color:var(--muted); font-size:.66rem; margin-top:.15rem;}

.fc-tip{position:fixed; z-index:60; width:min(280px,72vw); background:var(--surface); border:1px solid var(--border2); border-radius:var(--radius-sm); box-shadow:var(--shadow-md); padding:.8rem; pointer-events:none; font-size:.76rem;}
.fc-tip-head{display:flex; justify-content:space-between; gap:.5rem; border-bottom:1px solid var(--divider); padding-bottom:.4rem; margin-bottom:.5rem; font-family:var(--font-mono); font-weight:700; color:var(--accent); font-size:.72rem;}
.fc-tip-head .muted{color:var(--muted); font-weight:500;}
.fc-tip p{margin:.4rem 0 0; color:var(--muted); line-height:1.5;}
.fc-tip .row{display:flex; justify-content:space-between; background:var(--surface2); border:1px solid var(--border); border-radius:6px; padding:.3rem .5rem; color:var(--text);}

.fc-highlight{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.9rem; max-height:250px; overflow:auto; display:flex; flex-direction:column; gap:.7rem; font-size:.85rem; line-height:1.6; color:var(--text);}
.fc-hl-node{border-bottom:1px solid var(--divider); padding-bottom:.55rem;}
.fc-hl-node:last-child{border-bottom:none; padding-bottom:0;}
.fc-hl-node .meta{display:block; font-family:var(--font-mono); font-size:.6rem; color:var(--muted); margin-bottom:.25rem; text-transform:uppercase; letter-spacing:.06em;}
.fc-ent{display:inline-block; border:1px solid color-mix(in srgb,var(--mark-match) 45%,transparent); color:var(--mark-match); background:color-mix(in srgb,var(--mark-match) 12%,transparent); border-radius:5px; padding:.02rem .35rem; font-weight:700; cursor:pointer; font-size:.82rem;}
.fc-ent.sel{background:color-mix(in srgb,var(--mark-match) 24%,transparent); box-shadow:0 0 0 1px var(--mark-match);}
.fc-table-wrap{overflow:auto; border:1px solid var(--border); border-radius:var(--radius-sm);}
table.fc-table{width:100%; border-collapse:collapse; font-size:.78rem;}
.fc-table th{font-family:var(--font-mono); font-size:.62rem; text-transform:uppercase; letter-spacing:.06em; text-align:left; color:var(--muted); background:var(--viz-canvas); padding:.55rem .6rem; border-bottom:1px solid var(--border); font-weight:700;}
.fc-table td{padding:.5rem .6rem; border-bottom:1px solid var(--divider); color:var(--text);}
.fc-table tr{cursor:pointer;}
.fc-table tr:hover td{background:var(--hover-overlay);}
.fc-table tr.sel td{background:color-mix(in srgb,var(--mark-match) 10%,transparent);}
.fc-table .kg{font-family:var(--font-mono); color:var(--muted); font-size:.72rem;}
.fc-table .tf{font-family:var(--font-mono); color:var(--mark-match); font-weight:700;}
.fc-cat{display:inline-block; font-size:.62rem; font-weight:700; padding:.1rem .4rem; border-radius:5px; border:1px solid;}
.cat-Company{color:var(--cat-company); border-color:color-mix(in srgb,var(--cat-company) 40%,transparent); background:color-mix(in srgb,var(--cat-company) 12%,transparent);}
.cat-Tech{color:var(--cat-tech); border-color:color-mix(in srgb,var(--cat-tech) 40%,transparent); background:color-mix(in srgb,var(--cat-tech) 12%,transparent);}
.cat-Agri{color:var(--cat-agri); border-color:color-mix(in srgb,var(--cat-agri) 40%,transparent); background:color-mix(in srgb,var(--cat-agri) 12%,transparent);}
.cat-Theory{color:var(--cat-theory); border-color:color-mix(in srgb,var(--cat-theory) 40%,transparent); background:color-mix(in srgb,var(--cat-theory) 12%,transparent);}
.cat-Place{color:var(--cat-place); border-color:color-mix(in srgb,var(--cat-place) 40%,transparent); background:color-mix(in srgb,var(--cat-place) 12%,transparent);}
.cat-Organization,.cat-System,.cat-General,.cat-{color:var(--cat-general); border-color:var(--border); background:var(--surface);}
.fc-empty{padding:1.5rem; text-align:center; color:var(--muted); font-family:var(--font-mono); font-size:.76rem; border:1px dashed var(--border); border-radius:var(--radius-sm);}
.fc-kg-graph{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); min-height:230px; display:flex; align-items:center; justify-content:center; overflow:hidden;}
.fc-kg-def{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.7rem; min-height:90px;}
.fc-kg-def .id{font-family:var(--font-mono); font-size:.66rem; font-weight:700; color:var(--mark-match); background:color-mix(in srgb,var(--mark-match) 12%,transparent); border:1px solid color-mix(in srgb,var(--mark-match) 30%,transparent); border-radius:5px; padding:.1rem .4rem;}
.fc-kg-def .w{font-family:var(--font-mono); font-size:.66rem; color:var(--muted); float:right;}
.fc-kg-def p{font-size:.8rem; color:var(--text); margin:.5rem 0 0; line-height:1.5;}

.fc-term{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.7rem; font-family:var(--font-mono); font-size:.72rem; display:flex; flex-direction:column; gap:.5rem;}
.fc-term-log{overflow:auto; max-height:320px; display:flex; flex-direction:column; gap:.2rem;}
.fc-term-head{display:flex; justify-content:space-between; color:var(--muted); border-bottom:1px solid var(--divider); padding-bottom:.3rem; font-size:.62rem;}
.fc-term-row{display:flex; justify-content:space-between; gap:.6rem; padding:.12rem .2rem; border-radius:4px;}
.fc-term-row:hover{background:var(--hover-overlay);}
.fc-term-row .tok{color:var(--warning); font-weight:700; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;}
.fc-term-row .ts{color:var(--muted); margin-right:.4rem;}
.fc-term-row .hex{color:var(--muted);}
.fc-term-row .bkt{color:var(--accent); font-weight:700; margin-left:.4rem;}
.fc-term-form{display:flex; gap:.4rem; align-items:center; border-top:1px solid var(--divider); padding-top:.5rem;}
.fc-term-form .pr{color:var(--warning); font-weight:700;}
.fc-term-form input{background:transparent; border:none; padding:.2rem; font-family:var(--font-mono); font-size:.74rem;}
.fc-term-form input:focus{box-shadow:none; border:none;}
.fc-cells{display:grid; grid-template-columns:repeat(16,1fr); gap:2px; aspect-ratio:1/1; max-width:360px; margin:0 auto; width:100%;}
.fc-cell{aspect-ratio:1/1; border-radius:2px; background:var(--surface3); font-family:var(--font-mono); font-size:.5rem; display:grid; place-items:center; color:transparent; cursor:pointer;}
.fc-cell.on{background:linear-gradient(135deg,var(--w-mid),var(--doc-a)); color:#0b1120; font-weight:800;}
.fc-cell.hl{outline:2px solid var(--accent); outline-offset:-1px;}
.fc-inspect{font-family:var(--font-mono); font-size:.72rem; color:var(--muted); min-height:2.4em; border-top:1px solid var(--divider); padding-top:.5rem; display:flex; justify-content:space-between; gap:.6rem; flex-wrap:wrap;}
.fc-inspect .on{color:var(--warning); font-weight:700;}

.fc-scatter{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.5rem; aspect-ratio:1/1; max-height:400px; margin:0 auto; width:100%;}
.fc-scatter svg{width:100%; height:100%; display:block;}
.fc-ledger{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.8rem; font-family:var(--font-mono); font-size:.74rem; display:flex; flex-direction:column; gap:.5rem;}
.fc-ledger .formula{text-align:center; background:var(--surface); border:1px solid var(--border); border-radius:6px; padding:.4rem; color:var(--text);}
.fc-ledger .lrow{display:flex; justify-content:space-between; color:var(--muted); gap:1rem;}
.fc-ledger .lrow b{color:var(--text);}
.fc-ledger .va{color:var(--mark-query);} .fc-ledger .vb{color:var(--accent);}
.fc-ledger .verdict{border-top:1px solid var(--divider); padding-top:.5rem; line-height:1.5;}
.fc-ledger .verdict.good{color:var(--mark-match);} .fc-ledger .verdict.mid{color:var(--warning);} .fc-ledger .verdict.bad{color:var(--mark-query);}
.fc-viz-legend{display:flex; flex-wrap:wrap; gap:.6rem; justify-content:center; font-family:var(--font-mono); font-size:.66rem; color:var(--muted); background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.5rem;}
.fc-viz-legend .sw{width:10px; height:10px; border-radius:3px; display:inline-block; margin-right:.3rem; vertical-align:-1px;}

.fc-cmp-status{display:flex; align-items:center; gap:.5rem; font-family:var(--font-mono); font-size:.72rem; padding:.5rem .7rem; border-radius:var(--radius-sm); border:1px solid;}
.fc-cmp-status.ok{color:var(--mark-match); border-color:color-mix(in srgb,var(--mark-match) 35%,transparent); background:color-mix(in srgb,var(--mark-match) 10%,transparent);}
.fc-cmp-status.dirty{color:var(--warning); border-color:color-mix(in srgb,var(--warning) 35%,transparent); background:color-mix(in srgb,var(--warning) 10%,transparent);}
.fc-cmp-status.run{color:var(--accent); border-color:color-mix(in srgb,var(--accent) 35%,transparent); background:color-mix(in srgb,var(--accent) 10%,transparent);}
.fc-cmp-status .dot{width:8px; height:8px; border-radius:50%; background:currentColor; flex-shrink:0;}
.fc-cmp-run{display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.7rem;}
.fc-presets{display:flex; flex-wrap:wrap; gap:.4rem; align-items:center; font-family:var(--font-mono); font-size:.68rem; color:var(--muted);}
.fc-preset{border:1px solid var(--border); background:var(--surface); color:var(--text); border-radius:6px; padding:.22rem .5rem; cursor:pointer; font-size:.68rem;}
.fc-preset:hover{border-color:var(--accent);}
.fc-preset.sel{border-color:var(--accent); color:var(--accent); background:color-mix(in srgb,var(--accent) 10%,transparent);}
.fc-docmark{width:9px; height:9px; border-radius:50%; display:inline-block;}
.fc-docmark.a{background:var(--doc-a);} .fc-docmark.b{background:var(--doc-b);}
.fc-docmetrics{display:grid; grid-template-columns:repeat(3,1fr); gap:.4rem;}
.fc-docmetric{text-align:center; background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.45rem;}
.fc-docmetric .k{display:block; font-family:var(--font-mono); font-size:.55rem; text-transform:uppercase; color:var(--muted); letter-spacing:.06em;}
.fc-docmetric .v{font-family:var(--font-mono); font-size:1rem; font-weight:700;}
.fc-tags{display:flex; flex-wrap:wrap; gap:.3rem; min-height:1.6rem;}
.fc-tag{font-family:var(--font-mono); font-size:.64rem; font-weight:700; padding:.1rem .4rem; border-radius:5px; border:1px solid;}
.fc-tag.a{color:var(--doc-a); border-color:color-mix(in srgb,var(--doc-a) 40%,transparent); background:color-mix(in srgb,var(--doc-a) 12%,transparent);}
.fc-tag.b{color:var(--doc-b); border-color:color-mix(in srgb,var(--doc-b) 40%,transparent); background:color-mix(in srgb,var(--doc-b) 12%,transparent);}
.fc-tag.more{color:var(--muted); border-color:var(--border); background:var(--surface);}
.fc-bar{margin-bottom:1rem;}
.fc-bar .lab{display:flex; justify-content:space-between; align-items:center; margin-bottom:.35rem; font-family:var(--font-mono); font-size:.74rem; font-weight:700;}
.fc-bar .track{height:12px; background:var(--viz-canvas); border:1px solid var(--border); border-radius:999px; overflow:hidden;}
.fc-bar .fill{height:100%; border-radius:999px; transition:width .5s ease;}
.fc-bar.a .lab{color:var(--doc-a);} .fc-bar.a .fill{background:var(--doc-a);}
.fc-bar.b .lab{color:var(--doc-b);} .fc-bar.b .fill{background:var(--doc-b);}
.fc-verdict{background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.8rem; margin-top:.6rem;}
.fc-verdict-head{display:flex; align-items:center; justify-content:space-between; gap:.5rem; margin-bottom:.5rem;}
.fc-win{font-family:var(--font-mono); font-size:.64rem; font-weight:700; text-transform:uppercase; letter-spacing:.06em; padding:.15rem .5rem; border-radius:999px; border:1px solid;}
.fc-win.a{color:var(--doc-a); border-color:color-mix(in srgb,var(--doc-a) 40%,transparent); background:color-mix(in srgb,var(--doc-a) 12%,transparent);}
.fc-win.b{color:var(--doc-b); border-color:color-mix(in srgb,var(--doc-b) 40%,transparent); background:color-mix(in srgb,var(--doc-b) 12%,transparent);}
.fc-verdict p{margin:0; font-size:.84rem; color:var(--text); line-height:1.55;}
.fc-cmp-report{display:grid; grid-template-columns:8fr 4fr; gap:1rem; align-items:stretch;}
@media(max-width:820px){ .fc-cmp-report{grid-template-columns:1fr;} }
.fc-cmp-report.stale{opacity:.6;}
.fc-info{display:flex; gap:.6rem; align-items:flex-start; background:var(--viz-canvas); border:1px solid var(--border); border-radius:var(--radius-sm); padding:.65rem .75rem; font-size:.78rem; color:var(--muted); line-height:1.5;}
.fc-info .ic{color:var(--accent); flex-shrink:0; margin-top:.1rem;}
.fc-info strong{color:var(--text);}

.fc-kg-link{stroke:var(--mark-match); stroke-width:1.5; opacity:.5;}
.fc-kg-sat{fill:var(--viz-inset); stroke:var(--mark-match);}
.fc-kg-hub{fill:var(--viz-inset); stroke:var(--mark-match);}
.fc-kg-name{fill:var(--heading); font-family:var(--font-body); font-weight:700; font-size:10px;}
.fc-kg-cat{fill:var(--muted); font-family:var(--font-mono); font-weight:700; font-size:8px; text-transform:uppercase;}
.fc-kg-hubtext{fill:var(--mark-match); font-weight:800; font-size:11px;}

.fc-axis{stroke:var(--viz-line);}
.fc-axis-txt{fill:var(--muted); font-family:var(--font-mono); font-size:8px;}
.fc-dot-lbl{fill:var(--heading); font-family:var(--font-mono); font-weight:700; font-size:8px;}
.fc-dot{fill:var(--viz-line);}
.fc-dot.matched.dcat-company{fill:var(--cat-company);}
.fc-dot.matched.dcat-tech{fill:var(--cat-tech);}
.fc-dot.matched.dcat-agri{fill:var(--cat-agri);}
.fc-dot.matched.dcat-theory{fill:var(--cat-theory);}
.fc-dot.matched.dcat-place{fill:var(--cat-place);}
.fc-dot-doc{fill:var(--mark-query); stroke:var(--viz-canvas);}
.fc-dot-query{fill:var(--doc-a); stroke:var(--viz-canvas);}
.fc-link-good{stroke:var(--doc-a);}
.fc-link-bad{stroke:var(--mark-query);}

.fc-cmpdot{fill:var(--viz-line);}
.fc-cmpdot.a{fill:var(--doc-a);} .fc-cmpdot.b{fill:var(--doc-b);} .fc-cmpdot.both{fill:var(--mark-match);}
.fc-link-a{stroke:var(--doc-a); stroke-width:1.2;} .fc-link-b{stroke:var(--doc-b); stroke-width:1.2;}
.fc-mark-query{fill:var(--mark-query); stroke:var(--viz-canvas);}
.fc-mark-a{fill:var(--doc-a); stroke:var(--viz-canvas);}
.fc-mark-b{fill:var(--doc-b); stroke:var(--viz-canvas);}

.hero{padding:.8rem 1.25rem .4rem;}
.hero-inner{margin-bottom:.6rem;}
.hero-badge{margin-bottom:.45rem;}
.hero-title{font-size:clamp(1.45rem,3.1vw,1.9rem); margin-bottom:.35rem;}
.hero-sub{font-size:clamp(.86rem,1.4vw,.94rem);}
.tool{padding:.85rem;}
@media(min-width:640px){ .tool{padding:.9rem 1.1rem 1.2rem;} }
.fc{gap:.6rem;}
.fc-header{padding:.55rem; gap:.45rem;}
.fc-metric{padding:.3rem .5rem;}
.fc-metric .v{font-size:.95rem;}
.fc-metric .k{font-size:.55rem;}
.fc-step{padding:.4rem .5rem;}
.fc-panel{padding:.8rem; gap:.6rem;}
.fc-panel-head{padding-bottom:.5rem;}
.fc-modes{padding:.24rem;}
.fc-mode-btn{padding:.45rem .85rem;}
@media(max-width:600px){
  .fc-metrics{grid-template-columns:repeat(2,1fr);}
  .fc-steps{grid-template-columns:repeat(2,1fr);}
}
