/* FreeToolJar — shared design system */
:root {
  --font: 'Onest', system-ui, -apple-system, sans-serif;
  --bg: #ffffff; --surface: #f5f3ff; --text: #25213b;
  --accent: #7c6cf2; --accent-100: #efecff; --accent-600: #6a58e4; --accent-700: #5644c4; --accent-800: #43349a;
  --n-100: #ffffff; --n-200: #ebe8f5; --n-300: #d8d4e8; --n-500: #8b86a3; --n-700: #524d6a;
  --radius: 20px;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 84px; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--bg); color: var(--text); font-family: var(--font);
  font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; margin: 0 0 12px; }
p { margin: 0 0 14px; }
a { color: var(--accent-700); text-decoration: none; }
a:hover { color: var(--accent-600); }
img, svg { max-width: 100%; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 clamp(18px, 4vw, 40px); }

/* header */
header.site { position: sticky; top: 0; z-index: 40; background: rgba(255,255,255,.92); backdrop-filter: blur(14px); border-bottom: 1px solid var(--n-200); }
header.site .wrap { display: flex; align-items: center; gap: 24px; padding-top: 14px; padding-bottom: 14px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; color: var(--text); }
.logo .mark { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; width: 26px; height: 26px; }
.logo .mark span { border-radius: 6px; background: var(--accent); }
.logo .mark span:nth-child(2), .logo .mark span:nth-child(3) { background: #c3b9fb; }
.logo .mark span:nth-child(4) { border-radius: 50%; background: var(--accent-700); }
nav.main { display: flex; align-items: center; gap: 20px; font-size: 14.5px; font-weight: 700; margin-left: auto; }
nav.main a { color: var(--text); }
nav.main a:hover { color: var(--accent-600); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer; font-family: var(--font); font-weight: 700; font-size: 14px; padding: 11px 20px; border-radius: 999px; border: 1px solid transparent; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-600); color: #fff; }
.btn-ghost { border-color: var(--n-300); color: var(--text); background: #fff; }
.btn-ghost:hover { background: var(--n-200); }

/* cards */
.card { background: #fff; border: 1px solid var(--n-200); border-radius: var(--radius); padding: 22px; }
.field { margin-bottom: 16px; }
.field:last-child { margin-bottom: 0; }
.field label { display: block; font-size: 13px; font-weight: 700; color: var(--n-700); margin-bottom: 6px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row.three { grid-template-columns: 1fr 1fr 1fr; }
textarea, input[type=text], input[type=number], input[type=date], input[type=datetime-local], select {
  width: 100%; font-family: var(--font); font-size: 15px; color: var(--text);
  background: var(--surface); border: 1px solid var(--n-300); border-radius: 12px;
  padding: 10px 14px; outline: none;
}
textarea:focus, input:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-100); }
textarea { resize: vertical; min-height: 100px; line-height: 1.5; }
textarea.mono, .output.mono, input.mono { font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; font-size: 14px; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.stat-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin-top: 14px; }
.stat { background: var(--surface); border: 1px solid var(--n-200); border-radius: 12px; padding: 10px 12px; }
.stat .n { font-family: ui-monospace, monospace; font-size: 1.2rem; font-weight: 700; }
.stat .l { font-size: 0.76rem; color: var(--n-700); margin-top: 2px; }
.result-box { font-family: ui-monospace, monospace; font-size: 1.4rem; font-weight: 700; padding: 14px 16px; background: var(--surface); border: 1px solid var(--n-200); border-radius: 12px; }
.error-text { color: #c1443a; font-size: 0.85rem; min-height: 1.2em; margin-top: 8px; }

/* tool page layout */
.tool-hero { padding: 40px 0 8px; }
.tool-badge { display: inline-flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 16px; color: #fff; font-weight: 800; font-size: 15px; margin-bottom: 14px; box-shadow: 0 10px 22px rgba(40,30,110,.16); }
.tool-lede { color: var(--n-700); font-size: 17px; max-width: 60ch; }
.about-box { margin-top: 22px; padding: 20px 22px; border-radius: var(--radius); background: var(--surface); font-size: 14.5px; color: var(--n-700); line-height: 1.65; }
.about-box strong { color: var(--text); }
.faq h3 { font-size: 16px; margin-top: 20px; }
.faq p { font-size: 14.5px; color: var(--n-700); }
/* written guide: about, how-to steps and FAQs (tool, category and home pages) */
.guide { margin-top: 40px; max-width: 760px; }
.guide h2 { font-size: 22px; margin: 28px 0 10px; }
.guide h2:first-child { margin-top: 0; }
.guide p { color: var(--n-700); line-height: 1.7; }
.guide-steps { margin: 0 0 14px; padding-left: 22px; color: var(--n-700); line-height: 1.7; }
.guide-steps li { margin-bottom: 6px; padding-left: 4px; }
.guide-steps li::marker { color: var(--accent-700); font-weight: 800; }
.guide .faq h3 { font-size: 16px; margin: 18px 0 6px; }
.home-guide { padding-top: 12px; }
.crumbs { font-size: 13px; color: var(--n-500); margin: 22px 0 0; }
.tool-hero { padding-top: 22px; }
.crumbs a { color: var(--n-500); }
.crumbs a:hover { color: var(--accent-600); }

.related { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--n-200); }
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px,1fr)); gap: 12px; }
.related-grid a { display: flex; align-items: center; gap: 12px; padding: 10px 14px 10px 10px; border-radius: 14px; background: var(--surface); font-weight: 700; font-size: 14px; color: var(--text); line-height: 1.3; }
.related-grid a:hover { background: var(--accent-100); color: var(--accent-800); }

footer.site { border-top: 1px solid var(--n-200); margin-top: 60px; background: #fbfaff; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 28px; padding-top: 40px; padding-bottom: 28px; }
.footer-brand p { color: var(--n-700); font-size: 14px; margin: 10px 0 0; max-width: 30ch; }
.footer-col { display: flex; flex-direction: column; gap: 9px; }
.footer-col h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--n-500); margin: 0 0 4px; }
.footer-col a { color: var(--text); font-size: 14.5px; font-weight: 600; }
.footer-col a:hover { color: var(--accent-700); }
.footer-bottom { border-top: 1px solid var(--n-200); padding-top: 18px; padding-bottom: 28px; font-size: 13px; color: var(--n-500); }
.footer-bottom a { color: var(--n-700); }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
/* About, Contact, FAQ, Terms, Privacy */
.info-page { padding-top: 32px; max-width: 800px; }
.info-page h1 { font-size: clamp(32px, 4.5vw, 44px); }
.prose { margin-top: 18px; color: var(--n-700); line-height: 1.75; }
.prose h2 { font-size: 21px; color: var(--text); margin: 30px 0 10px; }
.prose ul { padding-left: 22px; } .prose li { margin-bottom: 8px; }
.prose strong { color: var(--text); }
.faq-page h2 { font-size: 18px; margin-top: 26px; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.contact-grid h2 { margin-top: 0; font-size: 19px; } .contact-grid .card h2 + p { margin-top: 0; }
.contact-card h2:not(:first-child) { margin-top: 22px; }
.contact-email { font-size: 20px; font-weight: 800; } .contact-email a { color: var(--accent-700); }
@media (max-width: 760px) { .contact-grid { grid-template-columns: 1fr; } }

/* header: categories dropdown + favs */
.cat-menu { position: relative; }
.cat-menu-btn { background: none; border: 0; font-family: var(--font); font-size: 14.5px; font-weight: 700; color: var(--text); cursor: pointer; padding: 6px 4px; }
.cat-menu-btn:hover { color: var(--accent-600); }
.cat-menu-list { position: absolute; left: 0; top: calc(100% + 10px); width: 260px; background: #fff; border: 1px solid var(--n-200); border-radius: 16px; box-shadow: 0 18px 40px rgba(40,30,110,.14); padding: 8px; display: grid; gap: 2px; }
.cat-menu-list[hidden] { display: none; }
.cat-menu-list a { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 10px; color: var(--text); font-size: 14px; font-weight: 600; }
.cat-menu-list a:hover { background: var(--surface); color: var(--accent-700); }
.mini-badge { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; font-size: 10.5px; font-weight: 800; flex: none; }
.favs-link { margin-left: auto; display: inline-flex; align-items: center; gap: 7px; font-size: 14.5px; font-weight: 700; color: var(--text); }
.favs-link .heart { color: var(--accent); }
.nav-link { margin-left: auto; font-size: 14.5px; font-weight: 700; color: var(--text); }
.nav-link + .favs-link { margin-left: 22px; }
.cat-menu-list a.menu-guides { display: none; }
@media (max-width: 480px) { .cat-menu-list a.menu-guides { display: flex; } }
/* guides / blog */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.post-card { display: flex; flex-direction: column; gap: 8px; padding: 18px; border: 1px solid var(--n-200); border-radius: 18px; background: #fff; color: var(--text); transition: transform .15s ease, box-shadow .15s ease; }
.post-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(90,70,200,.12); color: var(--text); }
.post-card-ico { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: oklch(0.94 0.045 var(--h)); color: oklch(0.5 0.14 var(--h)); }
.post-card b { font-size: 16.5px; line-height: 1.3; }
.post-card-desc { font-size: 13.5px; color: var(--n-700); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.post-card-meta { margin-top: auto; font-size: 12.5px; color: var(--n-500); font-weight: 600; }
.post-page { padding-top: 32px; }
.post-page article { max-width: 760px; }
.post-page h1 { font-size: clamp(30px, 4.5vw, 44px); }
.post-meta { color: var(--n-500); font-size: 14px; font-weight: 600; }
.post-body { color: var(--n-700); font-size: 16.5px; line-height: 1.75; }
.post-body h2 { font-size: 24px; color: var(--text); margin: 34px 0 10px; }
.post-body h3 { font-size: 18px; color: var(--text); margin: 24px 0 8px; }
.post-body strong { color: var(--text); }
.post-body ul, .post-body ol { padding-left: 24px; } .post-body li { margin-bottom: 8px; }
.post-body .formula { background: var(--surface); border-left: 4px solid var(--accent); border-radius: 10px; padding: 12px 16px; font-weight: 700; color: var(--text); }
.post-body pre { background: #1f1d2b; color: #f1effa; border-radius: 12px; padding: 14px 16px; overflow-x: auto; font-size: 14px; line-height: 1.6; }
.post-body code { font-family: ui-monospace, monospace; font-size: .92em; }
.post-body :not(pre) > code { background: var(--surface); padding: 2px 6px; border-radius: 6px; }
.post-table { width: 100%; border-collapse: collapse; margin: 14px 0 18px; font-size: 15px; display: block; overflow-x: auto; }
.post-table th, .post-table td { padding: 9px 12px; border-bottom: 1px solid var(--n-200); text-align: left; vertical-align: top; }
.post-table th { background: var(--surface); color: var(--text); }
.post-tools, .post-more { margin-top: 44px; }
.post-tools h2, .post-more h2 { font-size: 22px; }
.tool-guides .guide-links { display: grid; gap: 10px; }
.guide-links a { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; padding: 12px 16px; border-radius: 14px; background: var(--surface); color: var(--text); }
.guide-links a:hover { color: var(--accent-700); }
.guide-links span { font-size: 13px; color: var(--n-500); white-space: nowrap; }
/* keep the header on one line on phones */
@media (max-width: 480px) { header.site .wrap { gap: 12px; } .logo { font-size: 18px; gap: 8px; } .logo .mark { width: 22px; height: 22px; } .cat-menu-btn, .nav-link, .favs-link { font-size: 13.5px; } .nav-link + .favs-link { margin-left: 12px; } .favs-link { gap: 5px; } .nav-link { display: none; } .nav-link + .favs-link { margin-left: auto; } .favs-word { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } }
.fav-count { display: inline-grid; place-items: center; min-width: 24px; height: 20px; padding: 0 7px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12px; }

/* favourite buttons */
.fav-btn { padding: 8px 12px; font-size: 12.5px; white-space: nowrap; }
.fav-btn .heart { color: var(--n-700); }
.fav-btn.on { background: var(--accent-100); border-color: #cfc7fb; color: var(--accent-800); }
.fav-btn.on .heart { color: #e0457b; }
.tool-hero-actions { margin-top: 4px; }

/* homepage */
.hero { position: relative; overflow: hidden; }
.hero .wrap { position: relative; z-index: 1; padding-top: clamp(44px,7vw,86px); padding-bottom: clamp(44px,7vw,86px); }
.hero h1 { font-size: clamp(38px,5.4vw,62px); max-width: 12ch; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.hero-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hero-tile { position: relative; display: flex; flex-direction: column; min-height: 212px; padding: 12px 12px 18px; border-radius: 22px; background: var(--tint); color: var(--text); box-shadow: 0 16px 36px rgba(60,40,160,.10); transition: transform .15s ease; }
.hero-tile:hover { transform: translateY(-3px); color: var(--text); }
.hero-tile.solid { background: var(--ink); color: #fff; }
.hero-tile.solid:hover { color: #fff; }
.hero-tile-panel { position: relative; height: 120px; border-radius: 14px; background: rgba(255,255,255,.62); }
.hero-tile.solid .hero-tile-panel { background: rgba(255,255,255,.45); }
.hero-tile .t-badge { position: relative; left: auto; bottom: auto; margin: -24px 0 0 8px; }
.hero-tile-label { margin: 12px 8px 0; font-weight: 800; font-size: 16px; line-height: 1.25; }
/* icons (inline Lucide SVGs) */
.ico { display: block; flex: none; stroke-width: 2; }
.hero-tile-panel { display: grid; place-items: center; overflow: hidden; }
.hero-tile-panel .hero-art { color: var(--ink); stroke-width: 1.6; position: relative; z-index: 1; filter: drop-shadow(0 6px 12px rgba(40,30,110,.12)); }
.hero-tile.solid .hero-tile-panel .hero-art { color: #fff; }
.hero-tile-panel::before, .t-thumb::before { content: ''; position: absolute; inset: 0; border-radius: inherit;
  background: radial-gradient(circle at 18% 22%, color-mix(in srgb, var(--ink) 16%, transparent) 0 18px, transparent 19px),
              radial-gradient(circle at 86% 78%, color-mix(in srgb, var(--ink) 12%, transparent) 0 30px, transparent 31px),
              radial-gradient(color-mix(in srgb, var(--ink) 14%, transparent) 1.2px, transparent 1.6px) 0 0 / 14px 14px; }
.hero-tile.solid .hero-tile-panel::before { background: radial-gradient(circle at 18% 22%, rgba(255,255,255,.22) 0 18px, transparent 19px), radial-gradient(circle at 86% 78%, rgba(255,255,255,.16) 0 30px, transparent 31px), radial-gradient(rgba(255,255,255,.22) 1.2px, transparent 1.6px) 0 0 / 14px 14px; }
.t-art { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -50%) rotate(-4deg); display: grid; place-items: center; width: 72px; height: 72px; border-radius: 22px; background: #fff; color: var(--deep, var(--ink)); box-shadow: 0 10px 24px color-mix(in srgb, var(--ink) 22%, transparent), 0 0 0 6px color-mix(in srgb, #fff 55%, transparent); transition: transform .2s ease; z-index: 1; }
.t-art .ico { stroke-width: 1.8; }
.t-card:hover .t-art { transform: translate(-50%, -54%) rotate(0deg) scale(1.06); }
.tool-badge .ico { stroke-width: 2; }
.cat-tile .b .ico, .mini-badge .ico { stroke-width: 2.2; }
.rel-ico { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: #fff; color: var(--ink); flex: none; }

section.block { padding: 44px 0 12px; }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px,1fr)); gap: 12px; }
.cat-tile { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 18px 10px; border-radius: 18px; color: var(--text); font-size: 13.5px; font-weight: 600; transition: transform .15s ease, box-shadow .15s ease; }
.cat-tile:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(90,70,200,.12); color: var(--text); }
.cat-tile .b { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; color: #fff; font-weight: 800; font-size: 13px; }

.cat-tile .cat-name { line-height: 1.25; }
.cat-tile .cat-count { margin-top: -6px; font-size: 12px; font-weight: 700; opacity: .85; }
.section-sub { color: var(--n-700); margin: -10px 0 20px; }
/* homepage: tools on the left, "Most valuable websites" panel on the right */
.home-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; align-items: start; }
.home-side { position: sticky; top: 84px; padding-top: 44px; }
.home-main .tool-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.top-panel { border: 1px solid var(--n-200); border-radius: var(--radius); background: #fff; padding: 18px 16px 16px; }
.top-panel h2 { font-size: 18px; margin: 0 0 4px; }
.top-sub { font-size: 13px; color: var(--n-700); margin: 0 0 12px; line-height: 1.45; }
.top-list { list-style: none; margin: 0; padding: 0; }
.top-list li + li { border-top: 1px solid var(--n-200); }
.top-list a { display: flex; align-items: center; gap: 10px; padding: 9px 6px; border-radius: 10px; color: var(--text); }
.top-list a:hover { background: var(--surface); color: var(--text); }
.top-pos { width: 18px; flex: none; font-size: 12.5px; font-weight: 800; color: var(--n-500); text-align: right; }
.top-list img { flex: none; border-radius: 4px; }
.top-name { flex: 1; min-width: 0; line-height: 1.25; }
.top-name b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-name small { font-size: 11.5px; color: var(--n-500); }
.top-worth { flex: none; font-size: 13.5px; font-weight: 800; color: #1f7a45; font-family: ui-monospace, monospace; }
.top-msg { padding: 14px 6px; font-size: 13.5px; color: var(--n-700); }
.top-msg a { display: inline; padding: 0; color: var(--accent-700); }
.top-all { width: 100%; justify-content: center; margin-top: 12px; font-size: 13.5px; }
.top-note { font-size: 11.5px; color: var(--n-500); margin: 10px 0 0; }
@media (max-width: 960px) { .home-grid { grid-template-columns: minmax(0, 1fr); gap: 0; } .home-side { position: static; } }
/* homepage featured tool */
.spot-band { padding: 0 0 40px; }
.spot-form { display: flex; gap: 10px; margin-top: 16px; max-width: 620px; }
.spot-form input { flex: 1; font-size: 16px; padding: 13px 16px; border-radius: 14px; background: #fff; }
.spot-form .btn { padding: 12px 26px; font-size: 15px; }
.spot-links { margin-top: 10px; font-size: 13.5px; color: var(--n-700); }
@media (max-width: 600px) { .spot-form { flex-direction: column; } }
.spotlight { display: flex; gap: 28px; align-items: center; margin-top: 0; padding: 30px; border-radius: 24px; background: linear-gradient(120deg, var(--tint), #fff 70%); border: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); position: relative; overflow: hidden; }
.spotlight::after { content: ''; position: absolute; right: -60px; bottom: -90px; width: 260px; height: 260px; border-radius: 50%; background: color-mix(in srgb, var(--ink) 10%, transparent); }
.spot-art { flex: none; display: grid; place-items: center; width: 110px; height: 110px; border-radius: 30px; background: var(--ink); color: #fff; box-shadow: 0 16px 34px color-mix(in srgb, var(--ink) 38%, transparent); transform: rotate(-5deg); position: relative; z-index: 1; }
.spot-body { position: relative; z-index: 1; }
.spot-body h2 { font-size: clamp(24px, 3vw, 32px); margin: 8px 0 8px; }
.spot-body p { color: var(--n-700); max-width: 62ch; margin: 0; }
.spot-tag { display: inline-block; background: #fff; color: var(--deep); font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; border-radius: 999px; padding: 4px 12px; border: 1px solid color-mix(in srgb, var(--ink) 25%, transparent); }
@media (max-width: 700px) { .spotlight { flex-direction: column; align-items: flex-start; padding: 22px; } .spot-art { width: 76px; height: 76px; border-radius: 22px; } }
input.estimated { color: var(--n-500); font-style: italic; }
.cat-heading .hash.hot { margin-right: 6px; font-size: .85em; }
/* category pages */
.cat-hero { position: relative; overflow: hidden; }
.cat-hero .wrap { position: relative; z-index: 1; padding-top: 4px; padding-bottom: 40px; }
.cat-hero-row { display: flex; gap: 22px; align-items: flex-start; margin-top: 18px; }
.cat-hero-icon { display: grid; place-items: center; width: 76px; height: 76px; border-radius: 22px; background: var(--ink); color: #fff; flex: none; box-shadow: 0 12px 26px color-mix(in srgb, var(--ink) 35%, transparent); }
.cat-hero h1 { font-size: clamp(32px, 4.5vw, 46px); margin-bottom: 8px; }
.cat-hero .tool-lede { margin-bottom: 12px; }
.cat-hero-count { display: inline-block; background: var(--tint); color: var(--deep); font-weight: 800; font-size: 13px; border-radius: 999px; padding: 5px 14px; }
@media (max-width: 600px) { .cat-hero-row { flex-direction: column; gap: 14px; } .cat-hero-icon { width: 60px; height: 60px; border-radius: 18px; } }
.cat-section { padding-top: 44px; }
.cat-section[hidden] { display: none; }
.cat-heading { display: flex; align-items: center; gap: 2px; font-size: 28px; margin-bottom: 20px; }
.cat-heading .hash { color: var(--accent); }
.cat-heading::after { content: ''; flex: 1; height: 1px; background: var(--n-200); margin-left: 16px; }
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px,1fr)); gap: 16px; }
.t-card { display: flex; flex-direction: column; padding: 12px 12px 18px; border-radius: 20px; background: #fff; border: 1px solid var(--n-200); transition: transform .15s ease, box-shadow .15s ease; }
.t-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(90,70,200,.12); }
.t-thumb { position: relative; display: block; height: 130px; border-radius: 14px; background: var(--tint); }
.t-thumb .t-badge { z-index: 2; }
.t-badge { position: absolute; left: 10px; bottom: -22px; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px; background: #fff; border: 3px solid #fff; box-shadow: 0 4px 12px rgba(40,30,110,.08); font-weight: 800; font-size: 13px; }
.t-thumb .t-badge { background: var(--tint); }
.t-thumb-art { height: auto; background: none; border-radius: 14px; overflow: hidden; }
.t-thumb-art::before { display: none; }
.t-thumb-art img { display: block; width: 100%; height: auto; aspect-ratio: 5 / 3; border-radius: 14px; object-fit: cover; transition: transform .25s ease; }
.t-card:hover .t-thumb-art img { transform: scale(1.04); }
.t-thumb-art + .name { margin-top: 16px; }
/* tools without an illustration yet: a header in the tool's own hue with its icon */
.t-thumb-ico { height: auto; aspect-ratio: 5 / 3; overflow: hidden; display: grid; place-items: center; background: oklch(0.955 0.035 var(--h)); }
.t-thumb-ico::before { inset: auto; left: -8%; top: -34%; width: 36%; aspect-ratio: 1; border-radius: 50%; background: oklch(0.92 0.05 var(--h)); }
.t-thumb-ico::after { content: ''; position: absolute; right: -16%; bottom: -46%; width: 60%; aspect-ratio: 1; border-radius: 50%; background: oklch(0.9 0.06 var(--h)); }
.t-ico-tile { position: relative; z-index: 1; display: grid; place-items: center; width: 84px; height: 84px; border-radius: 24px; background: #fff; color: oklch(0.55 0.15 var(--h)); box-shadow: 0 12px 26px oklch(0.55 0.12 var(--h) / .22); transform: rotate(-4deg); transition: transform .2s ease; }
.t-ico-tile .ico { stroke-width: 1.8; }
.t-card:hover .t-ico-tile { transform: rotate(0deg) scale(1.05); }
.t-thumb-ico + .name { margin-top: 16px; }
.t-card .name { margin: 34px 10px 6px; font-weight: 800; font-size: 16px; line-height: 1.3; color: var(--text); }
.t-card .desc { margin: 0 10px 16px; font-size: 13.5px; color: var(--n-700); flex: 1; }
/* card buttons: a pill tinted in the tool's own hue (--h) + a round heart */
.card-actions { display: flex; gap: 8px; margin: auto 10px 0; padding-top: 4px; }
.btn-open { flex: 1; height: 42px; border-radius: 999px; display: flex; align-items: center; justify-content: center; gap: 8px;
  background: oklch(0.9 0.07 var(--h)); color: oklch(0.35 0.1 var(--h)); font-weight: 800; font-size: 14px; text-decoration: none; transition: background .15s, color .15s; }
.btn-open:hover { background: oklch(0.64 0.13 var(--h)); color: #fff; }
.btn-open .ico { stroke-width: 2.5; transition: transform .15s; }
.btn-open:hover .ico { transform: translateX(2px); }
.btn-fav { display: grid; place-items: center; width: 42px; height: 42px; flex: none; padding: 0; border: 0; border-radius: 50%; background: #f3f2f8; color: #55526a; cursor: pointer; transition: background .15s, color .15s; }
.btn-fav:hover, .btn-fav[aria-pressed="true"] { background: #ffe5e6; color: #e5484d; }
.btn-fav[aria-pressed="true"] .ico { fill: currentColor; }
.btn-open:focus-visible, .btn-fav:focus-visible { outline: 2px solid oklch(0.55 0.15 var(--h)); outline-offset: 2px; }
.empty-note { padding: 26px 20px; border-radius: 18px; background: var(--surface); color: var(--n-700); text-align: center; margin: 0; }
.empty-note[hidden] { display: none; }
.soon-note { margin-top: 14px; font-size: 13.5px; color: var(--n-500); }

/* shared tool components */
.drop { display: block; border: 2px dashed var(--n-300); border-radius: 16px; background: var(--surface); padding: 26px; text-align: center; cursor: pointer; font-size: 14px; color: var(--n-700); transition: border-color .15s ease, background .15s ease; }
.drop:hover, .drop.over { border-color: var(--accent); background: var(--accent-100); }
.drop input[type=file] { display: none; }
.drop .drop-main { display: block; color: var(--text); font-weight: 700; font-size: 15px; margin-bottom: 2px; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: 999px; background: var(--surface); border: 1px solid var(--n-200); }
.seg button { border: 0; background: none; font-family: var(--font); font-weight: 700; font-size: 13.5px; color: var(--n-700); padding: 7px 14px; border-radius: 999px; cursor: pointer; }
.seg button.on { background: #fff; color: var(--accent-700); box-shadow: 0 2px 6px rgba(40,30,110,.1); }
.checks { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 14px; }
.checks label { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; }
input[type=checkbox], input[type=radio] { accent-color: var(--accent); width: 16px; height: 16px; }
input[type=range] { width: 100%; accent-color: var(--accent); }
input[type=color] { width: 100%; height: 42px; padding: 3px; border: 1px solid var(--n-300); border-radius: 12px; background: var(--surface); cursor: pointer; }
input[type=time], input[type=email], input[type=url], input[type=tel] { width: 100%; font-family: var(--font); font-size: 15px; color: var(--text); background: var(--surface); border: 1px solid var(--n-300); border-radius: 12px; padding: 10px 14px; outline: none; }
.output { background: var(--surface); border: 1px solid var(--n-200); border-radius: 12px; padding: 14px 16px; white-space: pre-wrap; word-break: break-word; min-height: 52px; }
.muted { color: var(--n-500); font-size: 13.5px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-sm { padding: 7px 12px; font-size: 12.5px; }
.preview-canvas { display: block; max-width: 100%; height: auto; margin: 0 auto; border-radius: 12px; background: repeating-conic-gradient(#eeeaf8 0 25%, #fff 0 50%) 0 0 / 20px 20px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--n-200); border-radius: 12px; }
table.data { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.data th, table.data td { padding: 8px 12px; text-align: right; border-bottom: 1px solid var(--n-200); white-space: nowrap; }
table.data th:first-child, table.data td:first-child { text-align: left; }
table.data th { background: var(--surface); font-weight: 700; position: sticky; top: 0; }
.big-result { font-size: clamp(30px,5vw,44px); font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
/* design generators: live preview stage + code block */
.gen-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 20px; align-items: start; }
.stage { display: grid; place-items: center; min-height: 300px; border-radius: 16px; background: repeating-conic-gradient(#f1eff8 0 25%, #fff 0 50%) 0 0 / 22px 22px; border: 1px solid var(--n-200); padding: 24px; overflow: hidden; position: relative; }
.code-out { position: relative; margin-top: 14px; }
.code-out pre { margin: 0; font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; font-size: 13px; line-height: 1.6; background: #1f1d2b; color: #e8e6f5; border-radius: 14px; padding: 16px 18px; white-space: pre-wrap; word-break: break-word; max-height: 360px; overflow: auto; }
.code-out .btn { position: absolute; top: 10px; right: 10px; padding: 6px 12px; font-size: 12px; background: rgba(255,255,255,.12); color: #fff; border: 0; }
.code-out .btn:hover { background: rgba(255,255,255,.22); color: #fff; }
.sl-row { display: grid; grid-template-columns: 110px 1fr 56px; gap: 10px; align-items: center; font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.sl-row output { font-family: ui-monospace, monospace; font-size: 12px; color: var(--n-500); text-align: right; }
@media (max-width: 900px) { .gen-grid { grid-template-columns: 1fr; } }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .field-row, .field-row.three { grid-template-columns: 1fr; row-gap: 0; }
  .field-row > .field { margin-bottom: 16px; }
  .stat-grid { grid-template-columns: repeat(2,1fr); }
  nav.main { display: none; }
  header.site .wrap { gap: 14px; }
  .hero-tile { min-height: 170px; }
  .hero-tile-panel { height: 80px; }
  .cat-heading { font-size: 23px; }
}
/* the featured-tool band sits directly below the hero */
.hero .wrap { padding-bottom: clamp(28px, 4vw, 44px); }
@media (max-width: 600px) { .spot-band .spot-art { display: none; } }
