/* ============================================================
   QuickUtils Hub — shared design system
   Default Light Theme with Dark Mode toggle.
   No external assets required to render.
   ============================================================ */
:root {
  color-scheme: light;
  --bg: #f8fafc;
  --bg-2: #ffffff;
  --panel: #ffffff;
  --panel-2: #f1f5f9;
  --line: #e2e8f0;
  --line-2: #cbd5e1;
  --text: #0f172a;
  --muted: #475569;
  --dim: #64748b;
  --cyan: #0284c7;
  --violet: #6366f1;
  --magenta: #db2777;
  --lime: #16a34a;
  --amber: #d97706;
  --red: #dc2626;
  --grad: linear-gradient(135deg, #2563eb, #7c3aed 52%, #db2777);
  --r: 16px;
  --r-sm: 10px;
  --shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.08), 0 2px 6px -1px rgba(15, 23, 42, 0.04);
  --container: min(1180px, 100% - 2rem);
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
@media (min-width: 640px) { :root { --container: min(1180px, 100% - 3rem); } }

html.dark {
  color-scheme: dark;
  --bg: #04050a;
  --bg-2: #070912;
  --panel: rgba(255, 255, 255, .04);
  --panel-2: rgba(255, 255, 255, .07);
  --line: rgba(255, 255, 255, .10);
  --line-2: rgba(255, 255, 255, .20);
  --text: #e9edf7;
  --muted: #8b93ad;
  --dim: #656d85;
  --cyan: #00f0ff;
  --violet: #7c5cff;
  --magenta: #ff2fb9;
  --lime: #7dff9b;
  --amber: #ffcf5c;
  --red: #ff5f7a;
  --grad: linear-gradient(120deg, var(--cyan), var(--violet) 52%, var(--magenta));
  --shadow: 0 24px 60px -30px rgba(0, 0, 0, .95);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100vh; overflow-x: hidden; position: relative;
  background: var(--bg); color: var(--text);
  font: 15.5px/1.6 "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.2s ease, color 0.2s ease;
}
body::before {
  content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(rgba(99, 102, 241, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99, 102, 241, 0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse 85% 60% at 50% 0%, #000 30%, transparent 100%);
  mask-image: radial-gradient(ellipse 85% 60% at 50% 0%, #000 30%, transparent 100%);
}
html.dark body::before {
  background-image:
    linear-gradient(rgba(124, 92, 255, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 92, 255, .07) 1px, transparent 1px);
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: -3; pointer-events: none;
  background:
    radial-gradient(680px 420px at 10% -5%, rgba(37, 99, 235, .08), transparent 62%),
    radial-gradient(720px 460px at 88% 2%, rgba(219, 39, 119, .06), transparent 60%),
    radial-gradient(880px 560px at 50% 105%, rgba(124, 58, 237, .07), transparent 65%);
}
html.dark body::after {
  background:
    radial-gradient(680px 420px at 10% -5%, rgba(0, 240, 255, .16), transparent 62%),
    radial-gradient(720px 460px at 88% 2%, rgba(255, 47, 185, .14), transparent 60%),
    radial-gradient(880px 560px at 50% 105%, rgba(124, 92, 255, .17), transparent 65%);
}

h1, h2, h3, h4 { font-family: "Space Grotesk", "Inter", system-ui, sans-serif; letter-spacing: -.02em; line-height: 1.2; margin: 0; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; display: block; }
button, input, textarea, select { font: inherit; color: inherit; }
::selection { background: rgba(99, 102, 241, .25); color: inherit; }
html.dark ::selection { background: rgba(124, 92, 255, .5); color: #fff; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; border-radius: 6px; }
code, kbd, pre { font-family: var(--mono); }

.container { width: var(--container); margin-inline: auto; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; top: 0; z-index: 200; background: var(--cyan); color: #fff; padding: .75rem 1.1rem; font-weight: 700; }
.skip:focus { left: 0; }

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 80;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  border-bottom: 1px solid var(--line);
}
html.dark .topbar {
  background: rgba(4, 5, 10, .8);
}
.topbar-in { width: var(--container); margin-inline: auto; min-height: 60px; display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; padding-block: .5rem; }
.brand { display: flex; align-items: center; gap: .6rem; font-family: "Space Grotesk"; font-weight: 700; font-size: 1.05rem; min-height: 44px; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--grad); color: #ffffff; box-shadow: 0 4px 12px -2px rgba(37, 99, 235, 0.4); }
html.dark .brand-mark { color: #04050a; box-shadow: 0 0 20px -5px rgba(0, 240, 255, .8); }
.brand-name { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; white-space: nowrap; font-weight: 800; }
.crumb { color: var(--dim); font-size: .88rem; }
.crumb a { color: var(--muted); }
.crumb a:hover { color: var(--cyan); }
.topbar .spacer { margin-left: auto; }
.back-link {
  display: inline-flex; align-items: center; gap: .5em; min-height: 40px; padding-inline: .85rem;
  border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--muted); font-size: .88rem; font-weight: 500;
  transition: all .16s ease;
}
.back-link:hover { color: var(--cyan); border-color: var(--cyan); background: var(--panel-2); }

.theme-toggle-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--panel); color: var(--text);
  cursor: pointer; transition: all 0.18s; font-size: 0.95rem;
}
.theme-toggle-btn:hover { border-color: var(--cyan); transform: translateY(-1px); }

/* ---------- tool page frame ---------- */
.tool { padding-block: clamp(26px, 4vw, 44px) clamp(48px, 7vw, 80px); }
.tool-head { margin-bottom: 1.6rem; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .55em; font-family: var(--mono); font-size: .72rem;
  letter-spacing: .2em; text-transform: uppercase; color: var(--cyan); margin-bottom: .6rem; font-weight: 600;
}
.eyebrow::before { content: ""; width: 24px; height: 2px; background: linear-gradient(90deg, transparent, var(--cyan)); }
.tool-head h1 { font-size: clamp(1.6rem, 4.2vw, 2.3rem); margin-bottom: .5rem; }
.tool-head p { color: var(--muted); max-width: 74ch; font-size: 1.02rem; }

/* ---------- panels ---------- */
.panel {
  background: var(--panel);
  border: 1px solid var(--line); border-radius: var(--r);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow); padding: clamp(16px, 2.4vw, 24px); position: relative; overflow: hidden;
}
html.dark .panel {
  background: linear-gradient(165deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .018));
}
.panel + .panel { margin-top: 1.25rem; }
.panel-title {
  display: flex; align-items: center; gap: .6rem; font-family: var(--mono); font-size: .74rem;
  letter-spacing: .16em; text-transform: uppercase; color: var(--dim); margin-bottom: .85rem; font-weight: 600;
}
.panel-title .grow { flex: 1; height: 1px; background: linear-gradient(90deg, var(--line), transparent); }
.grid { display: grid; gap: 1rem; }
.cols-2 { grid-template-columns: 1fr; }
@media (min-width: 880px) { .cols-2 { grid-template-columns: 1fr 1fr; } }
.cols-side { grid-template-columns: 1fr; }
@media (min-width: 960px) { .cols-side { grid-template-columns: 340px 1fr; } }

/* ---------- form controls ---------- */
label.lbl { display: block; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); font-family: var(--mono); margin-bottom: .4rem; font-weight: 600; }
textarea, input[type=text], input[type=number], input[type=search], select {
  width: 100%; background: #ffffff; border: 1px solid var(--line-2); border-radius: var(--r-sm);
  color: var(--text); padding: .75rem .85rem; outline: none; font-family: var(--mono); font-size: .9rem;
  transition: border-color .16s, box-shadow .16s;
}
html.dark textarea, html.dark input[type=text], html.dark input[type=number], html.dark input[type=search], html.dark select {
  background: rgba(0, 0, 0, .4); border-color: var(--line);
}
textarea { resize: vertical; min-height: 170px; line-height: 1.55; }
textarea.tall { min-height: 260px; }
textarea.short { min-height: 96px; }
input:focus, textarea:focus, select:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(2, 132, 199, .15); }
html.dark input:focus, html.dark textarea:focus, html.dark select:focus { border-color: rgba(0, 240, 255, .6); box-shadow: 0 0 0 3px rgba(0, 240, 255, .13); }
input::placeholder, textarea::placeholder { color: #94a3b8; }
html.dark input::placeholder, html.dark textarea::placeholder { color: #59617a; }
select {
  cursor: pointer; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 52%, calc(100% - 13px) 52%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 2.2rem;
}
input[type=color] { width: 52px; height: 42px; padding: 3px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: #ffffff; cursor: pointer; }
html.dark input[type=color] { background: rgba(0, 0, 0, .4); border-color: var(--line); }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; border-radius: 99px; background: var(--line-2); outline: none; cursor: pointer; }
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%;
  background: var(--cyan); border: 2px solid #ffffff; box-shadow: 0 2px 6px rgba(0, 0, 0, .2); cursor: pointer;
}
html.dark input[type=range]::-webkit-slider-thumb {
  background: var(--grad); border: 2px solid #04050a; box-shadow: 0 0 14px rgba(0, 240, 255, .8);
}
.field { margin-bottom: 1rem; }
.field:last-child { margin-bottom: 0; }
.hint { font-size: .8rem; color: var(--dim); margin-top: .35rem; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  border: 1px solid transparent; cursor: pointer; font-weight: 600; border-radius: 11px;
  padding: .65rem 1.15rem; min-height: 42px; font-size: .92rem;
  transition: transform .1s, filter .18s, border-color .18s, background .18s;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-grad { background: var(--grad); color: #ffffff; box-shadow: 0 6px 16px -4px rgba(37, 99, 235, .4); }
html.dark .btn-grad { color: #04050a; box-shadow: 0 12px 34px -18px rgba(124, 92, 255, .95); }
.btn-grad:hover:not(:disabled) { filter: brightness(1.1); }
.btn-ghost { background: var(--panel-2); border-color: var(--line-2); color: var(--text); }
.btn-ghost:hover:not(:disabled) { border-color: var(--cyan); background: #ffffff; }
html.dark .btn-ghost { background: var(--panel); border-color: var(--line); color: var(--text); }
html.dark .btn-ghost:hover:not(:disabled) { border-color: rgba(0, 240, 255, .45); background: var(--panel-2); }
.btn-sm { padding: .45rem .8rem; min-height: 36px; font-size: .82rem; border-radius: 9px; }
.btn-row { display: flex; gap: .55rem; flex-wrap: wrap; align-items: center; }
.btn-row.spread { justify-content: space-between; }

/* segmented control */
.seg { display: inline-flex; background: #e2e8f0; border: 1px solid var(--line); border-radius: 11px; padding: 3px; gap: 3px; flex-wrap: wrap; max-width: 100%; }
html.dark .seg { background: rgba(0, 0, 0, .4); }
.seg button {
  background: transparent; border: 0; color: var(--muted); padding: .5rem .85rem; min-height: 38px;
  border-radius: 8px; cursor: pointer; font-size: .85rem; font-weight: 600; transition: .16s; white-space: nowrap;
}
.seg button:hover { color: var(--text); }
.seg button[aria-pressed=true] { background: var(--panel); color: var(--text); box-shadow: 0 2px 4px rgba(0,0,0,.08); }
html.dark .seg button[aria-pressed=true] { background: var(--grad); color: #04050a; }

/* checkbox pills */
.checks { display: flex; flex-wrap: wrap; gap: .5rem; }
.chk {
  display: inline-flex; align-items: center; gap: .5em; background: var(--panel-2);
  border: 1px solid var(--line); border-radius: 99px; padding: .45rem .85rem; min-height: 40px;
  cursor: pointer; font-size: .85rem; transition: .16s; user-select: none;
}
html.dark .chk { background: rgba(0, 0, 0, .35); }
.chk:hover { border-color: var(--line-2); }
.chk input { accent-color: var(--cyan); width: 15px; height: 15px; margin: 0; }
.chk:has(input:checked) { border-color: var(--cyan); background: rgba(2, 132, 199, .08); color: var(--text); }
html.dark .chk:has(input:checked) { border-color: rgba(0, 240, 255, .55); background: rgba(0, 240, 255, .1); }

/* ---------- status / feedback ---------- */
.status { display: none; align-items: flex-start; gap: .6rem; padding: .75rem 1rem; border-radius: 11px; border: 1px solid; font-size: .88rem; margin-top: .9rem; animation: fade .2s ease; }
.status.show { display: flex; }
.status.ok { background: rgba(22, 163, 74, .08); border-color: rgba(22, 163, 74, .3); color: #15803d; }
html.dark .status.ok { background: rgba(125, 255, 155, .08); border-color: rgba(125, 255, 155, .35); color: #a9ffc4; }
.status.err { background: rgba(220, 38, 38, .08); border-color: rgba(220, 38, 38, .3); color: #b91c1c; }
html.dark .status.err { background: rgba(255, 95, 122, .09); border-color: rgba(255, 95, 122, .4); color: #ffb3bf; }
.status.info { background: rgba(2, 132, 199, .08); border-color: rgba(2, 132, 199, .3); color: #0369a1; }
html.dark .status.info { background: rgba(0, 240, 255, .08); border-color: rgba(0, 240, 255, .32); color: #9df3ff; }
@keyframes fade { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

.toast {
  position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 20px); z-index: 300;
  background: #0f172a; border: 1px solid var(--line-2); color: #ffffff;
  padding: .7rem 1.25rem; border-radius: 12px; font-size: .9rem; font-weight: 600;
  box-shadow: 0 16px 36px -10px rgba(0, 0, 0, .3); opacity: 0; pointer-events: none;
  transition: opacity .22s, transform .22s; display: flex; align-items: center; gap: .55em;
}
html.dark .toast {
  background: #0d1020; border-color: rgba(0, 240, 255, .5);
  box-shadow: 0 20px 44px -20px rgba(0, 240, 255, .8);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- output blocks ---------- */
.out {
  background: #f8fafc; border: 1px solid var(--line); border-radius: var(--r-sm);
  padding: .9rem 1rem; overflow: auto; font-family: var(--mono); font-size: .85rem;
  line-height: 1.6; white-space: pre-wrap; word-break: break-word; max-height: 460px; margin: 0;
  color: var(--text);
}
html.dark .out { background: rgba(0, 0, 0, .45); }
.out.tight { max-height: 320px; }
.out.scroll { white-space: pre; word-break: normal; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: .4rem 1rem; font-family: var(--mono); font-size: .85rem; }
.kv dt { color: var(--dim); }
.kv dd { margin: 0; word-break: break-all; }

.metrics { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(112px, 1fr)); }
.metric { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: .7rem .8rem; text-align: center; }
html.dark .metric { background: rgba(0, 0, 0, .32); }
.metric b { display: block; font-family: "Space Grotesk"; font-size: 1.25rem; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.metric span { font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }

/* strength meter */
.meter { height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; border: 1px solid var(--line); }
.meter i { display: block; height: 100%; width: 0; background: var(--grad); transition: width .3s, background .3s; }

/* ---------- diff ---------- */
.diff-line { display: block; padding: .1rem .6rem; font-family: var(--mono); font-size: .84rem; white-space: pre-wrap; word-break: break-word; border-left: 3px solid transparent; }
.diff-line.add { background: rgba(22, 163, 74, .1); border-left-color: var(--lime); color: #15803d; }
html.dark .diff-line.add { background: rgba(125, 255, 155, .11); color: #c6ffd9; }
.diff-line.del { background: rgba(220, 38, 38, .1); border-left-color: var(--red); color: #b91c1c; }
html.dark .diff-line.del { background: rgba(255, 95, 122, .11); color: #ffc4cd; }
.diff-line.ctx { border-left-color: transparent; color: var(--muted); }

/* ---------- preview panes ---------- */
.preview {
  background: #ffffff; color: #111111; border-radius: var(--r-sm); border: 1px solid var(--line);
  padding: 1rem 1.15rem; min-height: 170px; max-height: 460px; overflow: auto; font-size: .95rem; line-height: 1.6;
}
.preview > :first-child { margin-top: 0; }
.preview pre { background: #0f172a; color: #f8fafc; padding: .7rem .9rem; border-radius: 8px; overflow: auto; }
.preview code { font-family: var(--mono); font-size: .88em; background: rgba(99, 102, 241, .12); padding: .1em .35em; border-radius: 4px; }
.preview pre code { background: none; padding: 0; }
.preview blockquote { border-left: 3px solid var(--violet); margin: .7rem 0; padding: .2rem 0 .2rem .8rem; color: #475569; }
.preview table { border-collapse: collapse; width: 100%; }
.preview th, .preview td { border: 1px solid #e2e8f0; padding: .4rem .6rem; }
.preview img { max-width: 100%; }

/* ---------- swatches / gradient ---------- */
.swatches { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.swatch { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--panel); box-shadow: var(--shadow); }
.swatch .chip { height: 56px; }
.swatch .meta { padding: .5rem .6rem; font-family: var(--mono); font-size: .78rem; }
.swatch .meta b { display: block; color: var(--text); font-weight: 600; }
.swatch .meta span { color: var(--dim); }
.grad-preview { height: 170px; border-radius: 12px; border: 1px solid var(--line); margin-bottom: .9rem; }
.stop-row { display: flex; gap: .5rem; align-items: center; margin-bottom: .5rem; }

/* ---------- QR ---------- */
.qr-box { display: flex; align-items: center; justify-content: center; background: #ffffff; border-radius: 14px; border: 1px solid var(--line); padding: 16px; min-height: 220px; }
.qr-box canvas { image-rendering: pixelated; max-width: 100%; height: auto; }

/* ---------- SEO Sections: How to, Specs, FAQs, Related ---------- */
.seo-section { margin-top: 3.5rem; padding-top: 2.5rem; border-top: 1px solid var(--line); }
.seo-header { margin-bottom: 1.8rem; }
.seo-title { font-size: clamp(1.3rem, 3vw, 1.8rem); margin-bottom: .5rem; }
.seo-subtitle { color: var(--muted); font-size: .95rem; max-width: 72ch; }

/* 3-Step Guide */
.step-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-bottom: 2.5rem; }
@media (min-width: 768px) { .step-grid { grid-template-columns: repeat(3, 1fr); } }
.step-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--r);
  padding: 1.4rem; position: relative; box-shadow: var(--shadow);
}
.step-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 8px; font-weight: 700; font-family: var(--mono);
  background: var(--grad); color: #ffffff; margin-bottom: 0.8rem; font-size: 0.9rem;
}
html.dark .step-badge { color: #04050a; }
.step-card h3 { font-size: 1.05rem; margin-bottom: 0.4rem; color: var(--text); }
.step-card p { font-size: 0.88rem; color: var(--muted); line-height: 1.55; }

/* 4 Specs Cards */
.spec-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-bottom: 2.5rem; }
@media (min-width: 640px) { .spec-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .spec-grid { grid-template-columns: repeat(4, 1fr); } }
.spec-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--r);
  padding: 1.25rem; box-shadow: var(--shadow);
}
.spec-icon {
  width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(37, 99, 235, 0.1); color: var(--cyan); margin-bottom: 0.75rem; font-size: 1.1rem;
}
html.dark .spec-icon { background: rgba(0, 240, 255, 0.15); }
.spec-card h3 { font-size: 0.98rem; margin-bottom: 0.35rem; color: var(--text); }
.spec-card p { font-size: 0.85rem; color: var(--muted); line-height: 1.5; }

/* FAQ Accordions (<details> & <summary> native HTML5) */
.faq-list { display: flex; flex-direction: column; gap: 0.75rem; margin-bottom: 2.5rem; }
details.faq-item {
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  overflow: hidden; transition: border-color 0.2s, box-shadow 0.2s; box-shadow: var(--shadow);
}
details.faq-item:hover { border-color: var(--line-2); }
details.faq-item > summary.faq-q {
  padding: 1.1rem 1.25rem; font-weight: 600; font-size: 0.96rem; color: var(--text);
  cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  user-select: none; list-style: none;
}
details.faq-item > summary::-webkit-details-marker { display: none; }
details.faq-item > summary::marker { display: none; }
details.faq-item > summary.faq-q i { font-size: 0.82rem; color: var(--dim); transition: transform 0.25s ease; }
details.faq-item[open] > summary.faq-q i { transform: rotate(180deg); color: var(--cyan); }
details.faq-item .faq-a {
  padding: 0.85rem 1.25rem 1.15rem; color: var(--muted); font-size: 0.9rem; line-height: 1.6;
  border-top: 1px solid var(--line);
}
details.faq-item .faq-a p { margin: 0; }

/* Related Tools Grid */
.related-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .related-grid { grid-template-columns: repeat(4, 1fr); } }
.related-card {
  display: flex; flex-direction: column; gap: 0.4rem; padding: 1.1rem;
  background: var(--panel); border: 1px solid var(--line); border-radius: 14px;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s; box-shadow: var(--shadow);
}
.related-card:hover {
  transform: translateY(-3px); border-color: var(--cyan);
}
.related-card .ico {
  width: 36px; height: 36px; border-radius: 8px; display: grid; place-items: center;
  background: rgba(37, 99, 235, 0.1); color: var(--cyan); font-size: 0.95rem; margin-bottom: 0.3rem;
}
html.dark .related-card .ico { background: rgba(0, 240, 255, 0.15); }
.related-card h4 { font-size: 0.92rem; color: var(--text); }
.related-card p { font-size: 0.8rem; color: var(--muted); flex: 1; }
.related-card .go { font-family: var(--mono); font-size: 0.7rem; color: var(--cyan); letter-spacing: 0.1em; text-transform: uppercase; }

/* Breadcrumb */
.tool-breadcrumb {
  display: flex; align-items: center; gap: 0.5rem; font-size: 0.82rem; color: var(--dim);
  margin-bottom: 1.2rem; font-family: var(--mono);
}
.tool-breadcrumb a { color: var(--muted); }
.tool-breadcrumb a:hover { color: var(--cyan); }
.tool-breadcrumb span { opacity: 0.6; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line); margin-top: 3.5rem; padding-block: 2rem;
  color: var(--dim); font-size: .85rem; text-align: center; background: var(--bg);
}
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--cyan); }

@media print {
  .topbar, .site-footer, .btn, .seg, .search-wrap, .theme-toggle-btn { display: none !important; }
  body { background: #fff; color: #000; }
  body::before, body::after { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
