@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* ============================================
   Bismuth Solutions — Global Stylesheet
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:          #0d1117;
  --surface:     #161b22;
  --surface2:    #21262d;
  --border:      #30363d;
  --accent:      #7c3aed;
  --accent-h:    #6d28d9;
  --accent2:     #60a5fa;
  --text:        #e6edf3;
  --muted:       #8b949e;
  --success:     #3fb950;
  --danger:      #f85149;
  --radius:      10px;
  --radius-sm:   6px;
  --shadow:      0 4px 24px rgba(0,0,0,.5);
  --font:        'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --mono:        'Courier New', 'Consolas', monospace;
  --glow:        rgba(139,92,246,.3);
}

body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; min-height: 100vh; }
a { color: var(--accent2); text-decoration: none; transition: color .2s; }
a:hover { color: #93c5fd; text-decoration: underline; }

/* ─── HEADER ─── */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0 1rem;
  position: sticky; top: 0; z-index: 100;
  box-shadow: 0 2px 16px rgba(0,0,0,.35);
}
.header-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; gap: 1.5rem; height: 60px;
}
.logo { font-size: 1.25rem; font-weight: 800; color: var(--text); white-space: nowrap; }
.logo span { background: linear-gradient(90deg, #a78bfa, #60a5fa); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.nav { display: flex; gap: 1.2rem; list-style: none; flex: 1; }
.nav a { color: var(--muted); font-size: .9rem; }
.nav a:hover { color: var(--text); text-decoration: none; }

/* ─── AD SLOTS ─── */
.ad-bar {
  background: var(--surface); border-bottom: 1px solid var(--border);
  display: flex; justify-content: center; align-items: center;
  padding: 6px 1rem; min-height: 32px; overflow: hidden;
}
.ad-bar-mobile { display: none; }
.ad-label {
  font-size: .6rem; color: var(--muted); text-align: center;
  letter-spacing: .07em; text-transform: uppercase; margin-bottom: 2px;
}
.ad-rect { display: flex; flex-direction: column; align-items: center; margin: 1.25rem auto; }
.ad-sidebar { display: flex; flex-direction: column; align-items: center; gap: 1rem; position: sticky; top: 80px; }
.ad-native { margin: 1.5rem 0; }

/* ─── HERO ─── */
.hero {
  background: linear-gradient(150deg, #1a0835 0%, #0d1117 60%);
  padding: 5rem 1rem 4rem; text-align: center;
  border-bottom: 1px solid var(--border);
  position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(139,92,246,.13) 1px, transparent 1px);
  background-size: 28px 28px; pointer-events: none;
}
.hero::after {
  content: ''; position: absolute;
  width: 800px; height: 500px;
  background: radial-gradient(ellipse, rgba(139,92,246,.22) 0%, transparent 65%);
  top: -160px; left: 50%; transform: translateX(-50%);
  pointer-events: none;
}
.hero > * { position: relative; z-index: 1; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  background: rgba(139,92,246,.1); border: 1px solid rgba(139,92,246,.25);
  border-radius: 20px; padding: .35rem .9rem;
  font-size: .75rem; font-weight: 700; color: #a78bfa;
  text-transform: uppercase; letter-spacing: .1em;
  margin-bottom: 1.25rem;
}
.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 3.8rem); font-weight: 900; margin-bottom: 1rem;
  background: linear-gradient(130deg, #f0e6ff 0%, #c084fc 30%, #60a5fa 65%, #34d399 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  line-height: 1.15; letter-spacing: -.025em;
}
.hero p { color: var(--muted); font-size: 1.1rem; max-width: 520px; margin: 0 auto 2.25rem; line-height: 1.7; }
.search-wrap { max-width: 540px; margin: 0 auto; position: relative; }
.search-wrap input {
  width: 100%; padding: 1rem 1.25rem 1rem 3.2rem;
  border-radius: 40px; border: 1.5px solid rgba(139,92,246,.3);
  background: rgba(22,27,34,.92); backdrop-filter: blur(8px);
  color: var(--text); font-size: 1rem; font-family: var(--font); outline: none;
  transition: border-color .2s, box-shadow .2s;
  box-shadow: 0 4px 24px rgba(0,0,0,.4);
}
.search-wrap input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(139,92,246,.14), 0 4px 24px rgba(0,0,0,.4); }
.search-wrap input::placeholder { color: var(--muted); }
.search-wrap .si { position: absolute; left: 1.15rem; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; font-size: 1rem; }

/* ─── STATS STRIP ─── */
.stats-strip {
  background: var(--surface); border-bottom: 1px solid var(--border);
  display: flex; justify-content: center; flex-wrap: wrap;
}
.stat-pill {
  display: flex; align-items: center; gap: .5rem;
  padding: .8rem 1.6rem; font-size: .82rem; font-weight: 500; color: var(--muted);
  border-right: 1px solid var(--border);
}
.stat-pill:last-child { border-right: none; }
.stat-pill .dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.dot-purple { background: #a78bfa; }
.dot-blue   { background: #60a5fa; }
.dot-green  { background: #34d399; }
.dot-yellow { background: #fbbf24; }
.stat-pill strong { color: var(--text); font-weight: 700; }

/* ─── LAYOUT ─── */
.page-body {
  display: grid; grid-template-columns: 1fr 186px; gap: 2rem;
  max-width: 1200px; margin: 0 auto; padding: 2rem 1rem; align-items: start;
}
.tool-page {
  display: grid; grid-template-columns: 1fr 186px; gap: 2rem;
  max-width: 1200px; margin: 0 auto; padding: 2rem 1rem; align-items: start;
}
.container { max-width: 1200px; margin: 0 auto; padding: 0 1rem; }

/* ─── SECTION TITLE ─── */
.section-title {
  font-size: .75rem; font-weight: 700; color: var(--muted);
  text-transform: uppercase; letter-spacing: .12em;
  margin-bottom: 1.35rem;
  display: flex; align-items: center; gap: .75rem;
}
.section-title::after { content: ''; flex: 1; height: 1px; background: var(--border); }

/* ─── TOOL CARDS (homepage grid) ─── */
.tools-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.1rem;
}
.tool-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.5rem; display: flex; flex-direction: column; gap: .4rem;
  color: var(--text); transition: border-color .22s, transform .18s, box-shadow .22s;
  position: relative; overflow: hidden;
  animation: fadeUp .45s ease both;
}
.tool-card::before {
  content: ''; position: absolute; inset: 0; border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(139,92,246,.07), transparent 55%);
  opacity: 0; transition: opacity .25s; pointer-events: none;
}
.tool-card:hover {
  border-color: rgba(139,92,246,.55); transform: translateY(-4px);
  box-shadow: 0 0 0 1px rgba(139,92,246,.18), 0 20px 60px rgba(0,0,0,.55);
  text-decoration: none; color: var(--text);
}
.tool-card:hover::before { opacity: 1; }
.tool-card:nth-child(1){animation-delay:.04s}.tool-card:nth-child(2){animation-delay:.08s}
.tool-card:nth-child(3){animation-delay:.12s}.tool-card:nth-child(4){animation-delay:.16s}
.tool-card:nth-child(5){animation-delay:.20s}.tool-card:nth-child(6){animation-delay:.24s}
.tool-card:nth-child(7){animation-delay:.28s}.tool-card:nth-child(8){animation-delay:.32s}
.tool-card:nth-child(9){animation-delay:.36s}.tool-card:nth-child(10){animation-delay:.40s}
.tool-icon-wrap {
  width: 48px; height: 48px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.45rem; margin-bottom: .4rem; flex-shrink: 0;
}
.ic-purple { background: rgba(167,139,250,.1); border: 1px solid rgba(167,139,250,.22); }
.ic-blue   { background: rgba(96,165,250,.1);  border: 1px solid rgba(96,165,250,.22); }
.ic-green  { background: rgba(52,211,153,.1);  border: 1px solid rgba(52,211,153,.22); }
.ic-orange { background: rgba(251,146,60,.1);  border: 1px solid rgba(251,146,60,.22); }
.tool-name { font-weight: 700; font-size: 1rem; letter-spacing: -.01em; }
.tool-desc { font-size: .83rem; color: var(--muted); line-height: 1.5; flex: 1; }
.tool-arrow {
  display: inline-flex; align-items: center; gap: .3rem;
  margin-top: .65rem; font-size: .78rem; font-weight: 600;
  color: var(--accent); opacity: 0; transform: translateX(-6px);
  transition: opacity .22s, transform .22s;
}
.tool-card:hover .tool-arrow { opacity: 1; transform: translateX(0); }
.badge {
  display: inline-block; font-size: .65rem; padding: .12rem .45rem;
  border-radius: 20px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; width: fit-content; margin-top: .15rem;
}
.b-pop { background: rgba(167,139,250,.15); color: #a78bfa; }
.b-dev { background: rgba(96,165,250,.15);  color: #60a5fa; }
.b-txt { background: rgba(52,211,153,.15);  color: #34d399; }
.b-des { background: rgba(251,146,60,.15);  color: #fb923c; }

/* ─── TOOL PAGE ─── */
.tool-header { margin-bottom: 1.5rem; }
.tool-header h1 { font-size: 1.6rem; font-weight: 800; margin-bottom: .35rem; }
.tool-header p { color: var(--muted); font-size: .92rem; }
.breadcrumb { font-size: .8rem; color: var(--muted); margin-bottom: 1rem; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--text); }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; margin-bottom: 1.25rem; }

/* ─── FORMS ─── */
.flabel { display: block; font-size: .78rem; font-weight: 700; color: var(--muted); margin-bottom: .4rem; text-transform: uppercase; letter-spacing: .06em; }
input[type=text], input[type=number], input[type=email], textarea, select {
  width: 100%; padding: .6rem .85rem; border-radius: var(--radius-sm);
  border: 1.5px solid var(--border); background: var(--surface2);
  color: var(--text); font-size: .93rem; font-family: var(--font); outline: none;
  transition: border-color .2s;
}
input:focus, textarea:focus, select:focus { border-color: var(--accent); }
textarea { resize: vertical; min-height: 120px; font-family: var(--mono); }
input[type=range] { accent-color: var(--accent); width: 100%; }
input[type=checkbox], input[type=radio] { accent-color: var(--accent); width: 1rem; height: 1rem; cursor: pointer; }
input[type=color] { padding: .2rem; height: 40px; cursor: pointer; }
.frow { margin-bottom: 1rem; }
.fcheck { display: flex; align-items: center; gap: .55rem; margin-bottom: .45rem; cursor: pointer; }
.fcheck label { font-size: .9rem; color: var(--text); cursor: pointer; }

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .6rem 1.2rem; border-radius: var(--radius-sm); border: none;
  cursor: pointer; font-size: .9rem; font-weight: 600; font-family: var(--font);
  transition: background .15s, transform .1s;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-h); }
.btn-sec { background: var(--surface2); color: var(--text); border: 1px solid var(--border); }
.btn-sec:hover { background: var(--border); }
.btn-ok { background: rgba(63,185,80,.15); color: var(--success); border: 1px solid rgba(63,185,80,.3); }
.btn-ok:hover { background: rgba(63,185,80,.25); }
.btn-sm { padding: .35rem .75rem; font-size: .8rem; }
.btn-group { display: flex; gap: .55rem; flex-wrap: wrap; margin-top: .9rem; }

/* ─── OUTPUT ─── */
.output {
  background: var(--surface2); border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  padding: 1rem; font-family: var(--mono); font-size: .88rem; word-break: break-all;
  white-space: pre-wrap; min-height: 56px; position: relative;
}
.output-actions { display: flex; gap: .5rem; margin-top: .7rem; }

/* ─── STATS ─── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: .7rem; margin: 1rem 0; }
.stat { background: var(--surface2); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: .7rem; text-align: center; }
.stat-val { font-size: 1.5rem; font-weight: 800; color: var(--accent2); line-height: 1; }
.stat-lbl { font-size: .7rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin-top: .2rem; }

/* ─── TOAST ─── */
.toast {
  position: fixed; bottom: 1.5rem; right: 1.5rem; background: #1a7f37;
  color: #fff; padding: .65rem 1.1rem; border-radius: var(--radius-sm);
  font-weight: 600; font-size: .88rem; opacity: 0; transform: translateY(16px);
  transition: opacity .25s, transform .25s; pointer-events: none; z-index: 9999;
}
.toast.show { opacity: 1; transform: translateY(0); }

/* ─── SEO CONTENT BLOCK ─── */
.seo-block { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; margin-top: 1.5rem; }
.seo-block h2 { font-size: 1.05rem; margin-bottom: .65rem; }
.seo-block h3 { font-size: .92rem; color: var(--accent2); margin: .9rem 0 .35rem; }
.seo-block p { font-size: .85rem; color: var(--muted); margin-bottom: .6rem; line-height: 1.6; }
.seo-block ul { padding-left: 1.2rem; }
.seo-block li { font-size: .85rem; color: var(--muted); margin-bottom: .3rem; }

/* ─── LIGHT MODE ─── */
[data-theme="light"] {
  --bg:       #f6f8fa;
  --surface:  #ffffff;
  --surface2: #f0f3f6;
  --border:   #d0d7de;
  --text:     #1f2328;
  --muted:    #656d76;
  --shadow:   0 4px 24px rgba(0,0,0,.12);
}
[data-theme="light"] .hero { background: linear-gradient(150deg, #ede9fe 0%, #f6f8fa 60%); }
[data-theme="light"] .hero::before { background-image: radial-gradient(rgba(139,92,246,.08) 1px, transparent 1px); background-size: 28px 28px; }
[data-theme="light"] .hero::after { background: radial-gradient(ellipse, rgba(139,92,246,.12) 0%, transparent 65%); }
[data-theme="light"] .search-wrap input { background: rgba(255,255,255,.92); }

/* ─── THEME TOGGLE ─── */
.theme-toggle {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--surface2); border: 1.5px solid var(--border);
  font-size: 1rem; cursor: pointer; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: background .2s, border-color .2s;
}
.theme-toggle:hover { border-color: var(--accent); background: var(--surface); }

/* ─── HERO ACTIONS ─── */
.hero-actions {
  display: flex; align-items: center; gap: 1.25rem; margin-top: 1.25rem;
  justify-content: center; flex-wrap: wrap;
}
.btn-lucky {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .6rem 1.35rem; border-radius: 40px;
  background: rgba(139,92,246,.15); border: 1.5px solid rgba(139,92,246,.35);
  color: #a78bfa; font-size: .9rem; font-weight: 700; font-family: var(--font);
  cursor: pointer; transition: background .2s, border-color .2s, transform .15s;
}
.btn-lucky:hover { background: rgba(139,92,246,.28); border-color: rgba(139,92,246,.6); transform: scale(1.03); }
.kbd-hint { font-size: .78rem; color: var(--muted); }
.kbd-hint kbd {
  display: inline-block; padding: .1rem .4rem; border-radius: 4px;
  background: var(--surface2); border: 1px solid var(--border);
  font-family: var(--mono); font-size: .75rem; color: var(--text);
}

/* ─── KEYBOARD SHORTCUTS MODAL ─── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.65); backdrop-filter: blur(4px);
  z-index: 9999; display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity .22s;
}
.modal-overlay.open { opacity: 1; pointer-events: auto; }
.modal {
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px;
  padding: 1.75rem; width: 100%; max-width: 420px; box-shadow: 0 24px 80px rgba(0,0,0,.6);
  transform: translateY(16px); transition: transform .22s;
}
.modal-overlay.open .modal { transform: translateY(0); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.modal-header h2 { font-size: 1.1rem; font-weight: 800; }
.modal-close { background: none; border: none; color: var(--muted); font-size: 1.4rem; cursor: pointer; line-height: 1; padding: 0; }
.modal-close:hover { color: var(--text); }
.shortcut-list { display: flex; flex-direction: column; gap: .65rem; }
.shortcut-row { display: flex; align-items: center; gap: 1rem; }
.shortcut-row kbd {
  display: inline-block; padding: .2rem .55rem; border-radius: 6px;
  background: var(--surface2); border: 1px solid var(--border);
  font-family: var(--mono); font-size: .82rem; color: var(--text);
  min-width: 40px; text-align: center; flex-shrink: 0;
}
.shortcut-row span { font-size: .88rem; color: var(--muted); }

/* ─── NEW BADGE ─── */
.b-new { background: rgba(52,211,153,.15); color: #34d399; margin-left: .3rem; }

/* ─── TRENDING COUNT ─── */
.trend-count {
  display: block; font-size: .72rem; color: var(--muted);
  margin-top: .35rem; font-weight: 500; letter-spacing: -.01em;
}
.tools-grid.list-view .trend-count { display: none; }

/* ─── TOOL OF THE DAY ─── */
.totd-wrap { margin-bottom: 1.5rem; }
.totd-label {
  font-size: .72rem; font-weight: 700; color: #f59e0b; text-transform: uppercase;
  letter-spacing: .1em; margin-bottom: .55rem;
}
.totd-card {
  display: flex; align-items: center; gap: 1rem; padding: 1rem 1.2rem;
  background: linear-gradient(135deg, rgba(245,158,11,.08) 0%, rgba(139,92,246,.08) 100%);
  border: 1.5px solid rgba(245,158,11,.25); border-radius: 12px;
  text-decoration: none; transition: border-color .2s, background .2s, transform .15s;
}
.totd-card:hover { border-color: rgba(245,158,11,.5); transform: translateY(-1px); text-decoration: none; }
.totd-icon { font-size: 2rem; flex-shrink: 0; }
.totd-body { flex: 1; min-width: 0; }
.totd-name { font-size: 1rem; font-weight: 800; color: var(--text); margin-bottom: .2rem; }
.totd-desc { font-size: .82rem; color: var(--muted); line-height: 1.45;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.totd-cta { font-size: .82rem; font-weight: 700; color: #f59e0b; white-space: nowrap; flex-shrink: 0; }

/* ─── SHARE BUTTON ─── */
.btn-share {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .6rem 1.2rem; border-radius: 40px;
  background: rgba(96,165,250,.12); border: 1.5px solid rgba(96,165,250,.3);
  color: #93c5fd; font-size: .9rem; font-weight: 700; font-family: var(--font);
  cursor: pointer; transition: background .2s, border-color .2s;
}
.btn-share:hover { background: rgba(96,165,250,.22); border-color: rgba(96,165,250,.6); }

/* ─── TOAST NOTIFICATIONS ─── */
#toastHolder {
  position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  z-index: 99998; display: flex; flex-direction: column; align-items: center; gap: .5rem;
  pointer-events: none;
}
.toast {
  background: var(--surface); border: 1px solid var(--border); border-radius: 40px;
  padding: .55rem 1.3rem; font-size: .88rem; font-weight: 600; color: var(--text);
  box-shadow: 0 8px 32px rgba(0,0,0,.4); white-space: nowrap;
  opacity: 0; transform: translateY(12px); transition: opacity .25s, transform .25s;
}
.toast.show { opacity: 1; transform: translateY(0); }

/* ─── FAQ SECTION ─── */
.faq-section { margin: 2.5rem 0 1rem; }
.faq-title {
  font-size: 1.3rem; font-weight: 800; margin-bottom: 1.1rem;
  padding-bottom: .65rem; border-bottom: 1px solid var(--border);
}
.faq-list { display: flex; flex-direction: column; gap: .4rem; }
.faq-item {
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  overflow: hidden; transition: border-color .2s;
}
.faq-item[open] { border-color: var(--accent); }
.faq-item summary {
  padding: .9rem 1.1rem; font-weight: 700; font-size: .93rem; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; list-style: none;
  gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+'; font-size: 1.2rem; color: var(--muted); flex-shrink: 0; transition: transform .2s;
}
.faq-item[open] summary::after { content: '\2212'; }
.faq-item p, .faq-item > *:not(summary) { padding: 0 1.1rem .9rem; font-size: .88rem; color: var(--muted); line-height: 1.65; }
.faq-item a { color: var(--accent2); }

/* ─── CTA STRIP ─── */
.cta-strip {
  background: linear-gradient(135deg, #1a0835 0%, #0d1e3d 100%);
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 2.5rem 1.5rem;
}
.cta-inner {
  max-width: 900px; margin: 0 auto; display: flex; align-items: center;
  justify-content: space-between; gap: 2rem; flex-wrap: wrap;
}
.cta-text { display: flex; flex-direction: column; gap: .3rem; }
.cta-text strong { font-size: 1.15rem; font-weight: 900; color: var(--text); }
.cta-text span { font-size: .9rem; color: var(--muted); }
.cta-btns { display: flex; gap: .75rem; flex-wrap: wrap; flex-shrink: 0; }
.cta-btn {
  padding: .7rem 1.4rem; border-radius: 40px; font-size: .9rem; font-weight: 700;
  text-decoration: none; transition: all .2s; white-space: nowrap;
}
.cta-primary { background: var(--accent); color: #fff; }
.cta-primary:hover { background: var(--accent-h); text-decoration: none; color: #fff; }
.cta-sec { background: rgba(96,165,250,.12); border: 1.5px solid rgba(96,165,250,.3); color: #93c5fd; }
.cta-sec:hover { background: rgba(96,165,250,.22); text-decoration: none; color: #93c5fd; }

/* ─── TOP PROGRESS BAR ─── */
#topBar {
  position: fixed; top: 0; left: 0; height: 3px; z-index: 99999;
  background: linear-gradient(90deg, var(--accent) 0%, #60a5fa 60%, #a78bfa 100%);
  border-radius: 0 2px 2px 0; pointer-events: none; width: 0; opacity: 1;
}

/* ─── FAV + COPY CARD BUTTONS ─── */
.tool-card { position: relative; }
.fav-btn, .copy-btn {
  position: absolute; top: .65rem; width: 28px; height: 28px; border-radius: 7px;
  background: var(--surface2); border: 1px solid var(--border); cursor: pointer;
  font-size: .88rem; display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .15s, background .15s, color .15s, transform .15s;
  color: var(--muted); line-height: 1; z-index: 2;
}
.fav-btn { right: .65rem; }
.copy-btn { right: 2.55rem; }
.tool-card:hover .fav-btn,
.tool-card:hover .copy-btn { opacity: 1; }
.fav-btn.fav-on { opacity: 1 !important; color: #f87171; background: rgba(248,113,113,.12); border-color: rgba(248,113,113,.3); }
.fav-btn:hover { transform: scale(1.15); background: rgba(248,113,113,.15); color: #f87171; }
.copy-btn:hover { transform: scale(1.12); background: var(--surface); color: var(--accent2); }
.copy-btn.copy-ok { color: #34d399; background: rgba(52,211,153,.12); border-color: rgba(52,211,153,.3); }

/* ─── GRID / LIST VIEW TOGGLE ─── */
.grid-header {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem;
  padding-bottom: .6rem; border-bottom: 1px solid var(--border);
}
.grid-header .section-title { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }
.view-toggle { display: flex; gap: .3rem; }
.vt-btn {
  width: 32px; height: 32px; border-radius: 7px; background: var(--surface2);
  border: 1px solid var(--border); color: var(--muted); cursor: pointer; font-size: 1rem;
  display: flex; align-items: center; justify-content: center; transition: all .15s;
}
.vt-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.vt-btn:not(.active):hover { background: var(--surface); color: var(--text); }

/* ─── LIST VIEW LAYOUT ─── */
.tools-grid.list-view {
  display: flex; flex-direction: column; gap: .55rem;
}
.tools-grid.list-view .tool-card {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  grid-template-rows: auto auto;
  align-items: center; gap: .15rem .85rem; padding: .8rem 1rem; border-radius: 10px;
}
.tools-grid.list-view .tool-icon-wrap {
  grid-column: 1; grid-row: 1 / 3; width: 44px; height: 44px;
  border-radius: 10px; font-size: 1.2rem; align-self: center;
}
.tools-grid.list-view .tool-name { grid-column: 2; grid-row: 1; font-size: .93rem; margin-bottom: 0; }
.tools-grid.list-view .tool-desc {
  grid-column: 2; grid-row: 2; font-size: .77rem; margin: 0;
  overflow: hidden; -webkit-line-clamp: 1; display: -webkit-box; -webkit-box-orient: vertical;
}
.tools-grid.list-view .tool-arrow { grid-column: 3; grid-row: 1 / 3; align-self: center; flex-shrink: 0; }
.tools-grid.list-view .badge { display: none; }

/* ─── CATEGORY TABS ─── */
.cat-tabs { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.cat-tab {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .4rem .9rem; border-radius: 20px; border: 1.5px solid var(--border);
  background: transparent; color: var(--muted); font-size: .82rem; font-weight: 600;
  cursor: pointer; font-family: var(--font); transition: all .18s;
}
.cat-tab:hover { border-color: var(--accent); color: var(--text); }
.cat-tab.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.ct-count { background: rgba(255,255,255,.15); border-radius: 10px; padding: .05rem .38rem; font-size: .7rem; }
.cat-tab.active .ct-count { background: rgba(255,255,255,.25); }

/* ─── RECENTLY USED ─── */
.recent-strip { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.recent-pill {
  display: inline-flex; align-items: center; gap: .45rem;
  background: var(--surface); border: 1px solid var(--border); border-radius: 20px;
  padding: .4rem .85rem; font-size: .82rem; color: var(--text);
  text-decoration: none; transition: border-color .18s, background .18s;
}
.recent-pill:hover { border-color: var(--accent); background: var(--surface2); text-decoration: none; color: var(--text); }
.recent-icon { font-size: 1rem; }

/* ─── HAMBURGER / MOBILE NAV ─── */
.hamburger {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 36px; height: 36px; background: none; border: none;
  cursor: pointer; padding: 4px; margin-left: auto; flex-shrink: 0;
}
.hamburger span { display: block; height: 2px; border-radius: 2px; background: var(--text); transition: all .25s; }
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.mobile-nav {
  display: none; position: fixed; inset: 60px 0 0 0;
  background: var(--surface); border-top: 1px solid var(--border);
  z-index: 99; flex-direction: column; padding: 1rem; gap: .25rem; overflow-y: auto;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  padding: .9rem 1rem; border-radius: var(--radius-sm);
  color: var(--text); font-size: .97rem; font-weight: 500;
  border-bottom: 1px solid var(--border); text-decoration: none;
}
.mobile-nav a:hover { background: var(--surface2); text-decoration: none; }

/* ─── SCROLL TO TOP ─── */
.scroll-top {
  position: fixed; bottom: 1.5rem; left: 1.5rem;
  width: 42px; height: 42px; border-radius: 50%; border: 1.5px solid var(--border);
  background: var(--surface); color: var(--text); font-size: 1.1rem;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: translateY(12px); transition: opacity .25s, transform .25s;
  pointer-events: none; z-index: 998;
}
.scroll-top.show { opacity: 1; transform: translateY(0); pointer-events: auto; }
.scroll-top:hover { background: var(--surface2); border-color: var(--accent); }

/* ─── ANIMATIONS ─── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── FOOTER ─── */
.site-footer { background: var(--surface); border-top: 1px solid var(--border); padding: 2.5rem 1rem 1.5rem; margin-top: 4rem; }
.footer-grid { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.footer-brand p { color: var(--muted); font-size: .84rem; margin-top: .4rem; }
.footer-col h4 { font-size: .75rem; text-transform: uppercase; letter-spacing: .09em; color: var(--muted); margin-bottom: .75rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: .4rem; }
.footer-col a { color: var(--muted); font-size: .84rem; }
.footer-col a:hover { color: var(--text); text-decoration: none; }
.footer-bottom { text-align: center; padding-top: 1.5rem; margin-top: 1.5rem; border-top: 1px solid var(--border); color: var(--muted); font-size: .78rem; }

/* ─── RESPONSIVE ─── */
@media (max-width: 800px) {
  .page-body, .tool-page { grid-template-columns: 1fr; }
  .ad-sidebar { display: none; }
  .ad-bar { display: none; }
  .ad-bar-mobile { display: flex; justify-content: center; padding: 6px 1rem; background: var(--surface); border-bottom: 1px solid var(--border); overflow: hidden; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .nav { display: none; }
  .hamburger { display: flex; }
  .cat-tabs { gap: .35rem; }
  .stat-pill { padding: .65rem .9rem; font-size: .77rem; }
  .totd-cta { display: none; }
  .hero-actions { gap: .75rem; }
  .btn-share { padding: .55rem .95rem; font-size: .82rem; }
  .cta-inner { flex-direction: column; align-items: flex-start; gap: 1.25rem; }
  .cta-btns { width: 100%; }
  .cta-btn { flex: 1; text-align: center; }
  .faq-item summary { font-size: .88rem; }
  #toastHolder { width: 90%; }
  .toast { text-align: center; white-space: normal; max-width: 280px; }
}
