:root {
  --bg: #f8fafc;
  --bg-mesh-1: rgba(37, 99, 235, 0.11);
  --bg-mesh-2: rgba(99, 102, 241, 0.10);
  --bg-mesh-3: rgba(132, 204, 22, 0.09);
  --surface: #ffffff;
  --surface-alt: #f1f5f9;
  --surface-glass: rgba(255, 255, 255, 0.82);
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --text: #0f172a;
  --text-muted: #475569;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-soft: rgba(37, 99, 235, 0.09);
  --primary-glow: rgba(37, 99, 235, 0.25);
  --accent: #06b6d4;
  --volt: #65a30d;
  --volt-bright: #a3e635;
  --volt-soft: rgba(132, 204, 22, 0.14);
  --danger: #dc2626;
  --warning: #d97706;
  --success: #16a34a;
  --radius: 16px;
  --radius-sm: 11px;
  --radius-xs: 8px;
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 2px 8px -2px rgba(15, 23, 42, 0.07);
  --shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 18px 40px -10px rgba(15, 23, 42, 0.12), 0 4px 12px -2px rgba(15, 23, 42, 0.05);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="dark"] {
  --bg: #070b14;
  --bg-mesh-1: rgba(59, 130, 246, 0.18);
  --bg-mesh-2: rgba(129, 140, 248, 0.14);
  --bg-mesh-3: rgba(163, 230, 53, 0.11);
  --surface: #0f172a;
  --surface-alt: #172033;
  --surface-glass: rgba(15, 23, 42, 0.80);
  --border: #1e293b;
  --border-strong: #334155;
  --text: #f8fafc;
  --text-muted: #94a3b8;
  --primary: #3b82f6;
  --primary-hover: #60a5fa;
  --primary-soft: rgba(59, 130, 246, 0.15);
  --primary-glow: rgba(59, 130, 246, 0.35);
  --volt: #a3e635;
  --volt-bright: #bef264;
  --volt-soft: rgba(163, 230, 53, 0.14);
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 3px 10px -2px rgba(0, 0, 0, 0.42);
  --shadow: 0 6px 24px -4px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 24px 48px -12px rgba(0, 0, 0, 0.65);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Plus Jakarta Sans', 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 80% 50% at 15% -10%, var(--bg-mesh-1), transparent 60%),
    radial-gradient(ellipse 70% 45% at 88% -5%, var(--bg-mesh-2), transparent 55%),
    radial-gradient(ellipse 50% 35% at 50% 15%, var(--bg-mesh-3), transparent 60%);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 20px; }
.hidden { display: none !important; }
.muted { color: var(--text-muted); }

/* ==================== HEADER / GLASS TOPBAR ==================== */
.topbar {
  position: sticky; top: 0; z-index: 45;
  background: var(--surface-glass);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.2s var(--ease);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; min-height: 68px; flex-wrap: wrap; padding: 8px 0;
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; color: inherit; }
.brand-logo {
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, #2563eb 0%, #6366f1 55%, #0ea5e9 100%);
  color: #fff; display: grid; place-items: center; font-size: 19px; flex-shrink: 0;
  box-shadow: 0 6px 16px -4px var(--primary-glow);
  transition: transform 0.22s var(--ease);
}
.brand:hover .brand-logo { transform: rotate(-6deg) scale(1.06); }
.brand strong { display: block; font-size: 1.06rem; font-weight: 800; letter-spacing: -0.02em; line-height: 1.18; }
.brand small { color: var(--text-muted); font-size: 0.73rem; font-weight: 500; }
.topbar-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.topbar-select {
  padding: 7px 10px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface-alt); color: var(--text); font-family: inherit;
  font-size: 0.82rem; font-weight: 600; cursor: pointer; transition: border-color 0.15s;
}
.topbar-select:hover, .topbar-select:focus { border-color: var(--primary); outline: none; }

.kbd-hint {
  display: inline-flex; align-items: center; padding: 2px 6px;
  border-radius: 6px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--text-muted);
  font-family: ui-monospace, SFMono-Regular, monospace; font-size: 0.7rem; font-weight: 700;
}

/* ==================== BUTTONS ==================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 10px 16px; border-radius: var(--radius-sm); border: 1px solid transparent;
  font-family: inherit; font-size: 0.89rem; font-weight: 600; cursor: pointer;
  text-decoration: none; transition: transform 0.18s var(--ease), background 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.btn:active:not(:disabled) { transform: scale(0.98); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary {
  background: linear-gradient(135deg, var(--primary), #4f46e5);
  color: #fff; box-shadow: 0 4px 14px -3px var(--primary-glow);
}
.btn-primary:hover:not(:disabled) {
  filter: brightness(1.06); transform: translateY(-1px);
  box-shadow: 0 8px 20px -4px var(--primary-glow);
}
.btn-secondary { background: var(--surface-alt); color: var(--text); border-color: var(--border); }
.btn-secondary:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.btn-success { background: linear-gradient(135deg, #16a34a, #059669); color: #fff; }
.btn-success:hover:not(:disabled) { filter: brightness(1.06); transform: translateY(-1px); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { background: var(--surface-alt); border-color: var(--border-strong); }
.btn-icon { width: 38px; height: 38px; padding: 0; background: var(--surface-alt); border-color: var(--border); }
.btn-icon:hover { border-color: var(--primary); }
.btn-sm { padding: 7px 12px; font-size: 0.82rem; }
.btn-block { width: 100%; }
.badge {
  background: var(--primary); color: #fff; border-radius: 999px;
  padding: 1px 7px; font-size: 0.71rem; font-weight: 700;
}

/* ==================== HERO + COMMAND SEARCH ==================== */
.hero { padding: 48px 0 26px; text-align: center; position: relative; }
.privacy-pill {
  display: inline-flex; align-items: center; gap: 7px; padding: 6px 16px;
  border-radius: 999px; background: var(--surface); border: 1px solid var(--border);
  color: var(--primary); font-size: 0.8rem; font-weight: 700; margin-bottom: 18px;
  box-shadow: var(--shadow-xs);
}
.hero h1 {
  margin: 0 auto 14px; max-width: 860px;
  font-size: clamp(2rem, 4.4vw, 3.35rem); font-weight: 800;
  letter-spacing: -0.035em; line-height: 1.09;
  background: linear-gradient(135deg, var(--text) 35%, var(--primary) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub {
  margin: 0 auto 26px; max-width: 720px; color: var(--text-muted);
  font-size: clamp(0.96rem, 1.4vw, 1.08rem);
}
.hero-sub strong { color: var(--text); }

/* Trust Stats Strip */
.trust-strip {
  display: inline-flex; flex-wrap: wrap; justify-content: center; gap: 10px 22px;
  margin-bottom: 24px; padding: 10px 20px; border-radius: 999px;
  background: var(--surface-glass); border: 1px solid var(--border);
  font-size: 0.82rem; font-weight: 600; color: var(--text-muted);
  box-shadow: var(--shadow-xs);
}
.trust-item { display: inline-flex; align-items: center; gap: 6px; }
.trust-item strong { color: var(--text); font-weight: 800; }

/* Search Input */
.search-wrap { position: relative; max-width: 720px; margin: 0 auto 14px; }
.search-wrap input {
  width: 100%; padding: 17px 96px 17px 48px; border-radius: 16px;
  border: 2px solid var(--border); background: var(--surface); color: var(--text);
  font-family: inherit; font-size: 1rem; font-weight: 500;
  box-shadow: var(--shadow-lg); outline: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.search-wrap input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-soft), var(--shadow-lg);
}
.search-icon { position: absolute; left: 17px; top: 50%; transform: translateY(-50%); font-size: 1.15rem; pointer-events: none; }
.search-kbd { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); pointer-events: none; }
.search-clear {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  background: var(--surface-alt); border: 1px solid var(--border); color: var(--text-muted);
  width: 28px; height: 28px; border-radius: 50%; cursor: pointer;
}

/* Quick Search Suggestion Chips */
.quick-chips {
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center;
  gap: 7px; margin: 0 auto 24px; max-width: 760px; font-size: 0.8rem;
}
.quick-chip {
  padding: 5px 12px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text-muted); font-family: inherit;
  font-size: 0.78rem; font-weight: 600; cursor: pointer;
  transition: all 0.16s var(--ease);
}
.quick-chip:hover {
  border-color: var(--primary); color: var(--primary);
  background: var(--primary-soft); transform: translateY(-1px);
}

/* Category Pills */
.category-bar { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.cat-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text-muted); font-family: inherit;
  font-size: 0.83rem; font-weight: 600; cursor: pointer;
  transition: all 0.18s var(--ease); box-shadow: var(--shadow-xs);
}
.cat-pill:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-1px); }
.cat-pill.active {
  background: linear-gradient(135deg, var(--primary), #4f46e5);
  border-color: transparent; color: #fff;
  box-shadow: 0 6px 16px -4px var(--primary-glow);
}
.cat-count {
  font-size: 0.72rem; opacity: 0.78; padding: 1px 6px; border-radius: 999px;
  background: rgba(148, 163, 184, 0.18);
}
.cat-pill.active .cat-count { background: rgba(255, 255, 255, 0.22); opacity: 1; }

/* ==================== AD SLOTS ==================== */
.ad-slot {
  background: var(--surface); border: 1px dashed var(--border-strong); border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center; text-align: center;
  padding: 12px; color: var(--text-muted); font-size: 0.82rem;
}
.ad-leaderboard { min-height: 76px; margin: 14px 0 26px; }
.ad-rectangle { min-height: 220px; }

/* ==================== BENTO POPULAR & RECENT SECTIONS ==================== */
.bento-section { margin-bottom: 30px; }
.section-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 14px;
}
.section-head h2 { margin: 0; font-size: 1.12rem; font-weight: 800; letter-spacing: -0.015em; display: flex; align-items: center; gap: 8px; }

.popular-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px;
}
.popular-card {
  position: relative; display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border);
  text-decoration: none; color: inherit; box-shadow: var(--shadow-xs);
  transition: transform 0.22s var(--ease), border-color 0.22s, box-shadow 0.22s;
  overflow: hidden;
}
.popular-card::before {
  content: ''; position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, var(--cat-accent, var(--primary)), transparent);
  opacity: 0.7; transition: opacity 0.2s;
}
.popular-card:hover {
  transform: translateY(-3px); border-color: var(--cat-accent, var(--primary));
  box-shadow: var(--shadow-lg);
}
.popular-card:hover::before { opacity: 1; }
.popular-body { flex: 1; min-width: 0; }
.popular-body h3 { margin: 0 0 3px; font-size: 0.94rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.popular-body p { margin: 0; font-size: 0.8rem; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.popular-arrow { font-size: 1rem; color: var(--text-muted); transition: transform 0.2s var(--ease), color 0.2s; }
.popular-card:hover .popular-arrow { transform: translateX(4px); color: var(--cat-accent, var(--primary)); }

.recent-strip { display: flex; flex-wrap: wrap; gap: 10px; }
.recent-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 12px;
  background: var(--surface); border: 1px solid var(--border);
  color: var(--text); text-decoration: none; font-size: 0.84rem; font-weight: 600;
  box-shadow: var(--shadow-xs); transition: all 0.18s var(--ease);
}
.recent-pill:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-2px); box-shadow: var(--shadow); }

/* ==================== CATEGORY ACCENT COLORS ==================== */
[data-cat="pdf"]      { --cat-accent: #e11d48; --cat-soft: rgba(225, 29, 72, 0.11); }
[data-cat="img"]      { --cat-accent: #7c3aed; --cat-soft: rgba(124, 58, 237, 0.11); }
[data-cat="media"]    { --cat-accent: #ea580c; --cat-soft: rgba(234, 88, 12, 0.11); }
[data-cat="recovery"] { --cat-accent: #059669; --cat-soft: rgba(5, 150, 105, 0.12); }
[data-cat="hardware"] { --cat-accent: #0284c7; --cat-soft: rgba(2, 132, 199, 0.12); }
[data-cat="finance"]  { --cat-accent: #2563eb; --cat-soft: rgba(37, 99, 235, 0.11); }
[data-cat="text"]     { --cat-accent: #9333ea; --cat-soft: rgba(147, 51, 234, 0.11); }
[data-cat="office"]   { --cat-accent: #0f766e; --cat-soft: rgba(15, 118, 110, 0.11); }
[data-cat="qr"]       { --cat-accent: #0891b2; --cat-soft: rgba(8, 145, 178, 0.11); }
[data-cat="security"] { --cat-accent: #16a34a; --cat-soft: rgba(22, 163, 74, 0.12); }
[data-cat="dev"]      { --cat-accent: #4f46e5; --cat-soft: rgba(79, 70, 229, 0.12); }

/* ==================== CATALOG GRID ==================== */
.main-content { padding-bottom: 64px; }
.catalog-header { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 16px; gap: 12px; }
.catalog-header h2 { margin: 0; font-size: 1.28rem; font-weight: 800; letter-spacing: -0.02em; }
.tools-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(265px, 1fr)); gap: 16px; }

.tool-card, a.tool-card {
  position: relative; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px; cursor: pointer;
  display: flex; flex-direction: column; gap: 10px;
  text-decoration: none; color: inherit; box-shadow: var(--shadow-xs);
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), border-color 0.22s;
}
.tool-card:hover {
  transform: translateY(-4px);
  border-color: var(--cat-accent, var(--primary));
  box-shadow: var(--shadow-lg);
}
.tool-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.tool-icon {
  width: 46px; height: 46px; border-radius: 13px;
  background: var(--cat-soft, var(--primary-soft));
  display: grid; place-items: center; font-size: 1.38rem; flex-shrink: 0;
  transition: transform 0.22s var(--ease);
}
.tool-card:hover .tool-icon, .popular-card:hover .tool-icon { transform: scale(1.08); }
.tool-fav-btn {
  background: transparent; border: none; font-size: 1.2rem; cursor: pointer;
  color: var(--text-muted); padding: 4px; border-radius: 8px; transition: background 0.15s, color 0.15s;
}
.tool-fav-btn:hover { background: var(--surface-alt); color: #f59e0b; }
.tool-fav-btn.is-fav { color: #f59e0b; }
.tool-card h3 { margin: 0; font-size: 0.98rem; font-weight: 700; letter-spacing: -0.01em; line-height: 1.3; }
.tool-card p { margin: 0; font-size: 0.84rem; color: var(--text-muted); flex: 1; line-height: 1.48; }
.tool-card-footer {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 0.74rem; font-weight: 600; gap: 6px; padding-top: 8px;
  border-top: 1px solid color-mix(in srgb, var(--border) 60%, transparent);
}
.cat-tag { color: var(--cat-accent, var(--text-muted)); font-weight: 700; }

.pill {
  display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px;
  border-radius: 999px; font-size: 0.72rem; font-weight: 700;
  background: var(--surface-alt); color: var(--text-muted);
}
.pill-local { background: rgba(22, 163, 74, 0.12); color: var(--success); }
.pill-api { background: rgba(217, 119, 6, 0.14); color: var(--warning); }

/* ==================== WORKSPACE & STATIC TOOL PAGES ==================== */
.workspace { padding: 20px 0 64px; }
.breadcrumb {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  font-size: 0.82rem; color: var(--text-muted); margin-bottom: 14px;
}
.breadcrumb a { color: var(--primary); text-decoration: none; font-weight: 600; }
.breadcrumb a:hover { text-decoration: underline; }

.workspace-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.workspace-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.workspace-layout { display: grid; grid-template-columns: minmax(0, 1fr) 336px; gap: 22px; align-items: start; }
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow);
}
.tool-header {
  display: flex; align-items: center; gap: 16px;
  padding-bottom: 18px; margin-bottom: 22px; border-bottom: 1px solid var(--border);
}
.tool-header-icon {
  width: 56px; height: 56px; border-radius: 15px;
  background: var(--cat-soft, var(--primary-soft));
  display: grid; place-items: center; font-size: 1.7rem; flex-shrink: 0;
}
.tool-header h1 { margin: 0 0 4px; font-size: clamp(1.28rem, 2.2vw, 1.56rem); font-weight: 800; letter-spacing: -0.02em; }
.tool-header p { margin: 0; font-size: 0.92rem; }

/* SEO Guide, Related Tools & FAQ */
.seo-guide { margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--border); }
.seo-guide h2 { margin: 0 0 10px; font-size: 1.14rem; font-weight: 800; }
.seo-guide ol, .seo-guide ul { padding-left: 20px; margin: 8px 0 16px; color: var(--text-muted); font-size: 0.9rem; }
.seo-guide li { margin-bottom: 6px; }
.seo-guide p { font-size: 0.9rem; color: var(--text-muted); margin: 0 0 12px; }

.related-tools-box { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--border); }
.related-tools-box h3 { margin: 0 0 12px; font-size: 1rem; font-weight: 800; }
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.related-link {
  display: flex; align-items: center; gap: 10px; padding: 11px 13px;
  border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface-alt); color: var(--text); text-decoration: none;
  font-size: 0.85rem; font-weight: 600; transition: all 0.18s var(--ease);
}
.related-link:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); transform: translateY(-2px); }

.tool-faq { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--border); }
.tool-faq h3 { margin: 0 0 10px; font-size: 1rem; font-weight: 800; }
.tool-faq details {
  background: var(--surface-alt); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 11px 15px; margin-bottom: 8px; font-size: 0.86rem;
}
.tool-faq summary { cursor: pointer; font-weight: 700; }
.tool-faq p { margin: 8px 0 0; color: var(--text-muted); }

/* ==================== FORMS & DROPZONE ==================== */
.dropzone {
  border: 2px dashed var(--border-strong); border-radius: var(--radius);
  padding: 36px 20px; text-align: center;
  background: linear-gradient(180deg, var(--surface-alt), color-mix(in srgb, var(--surface-alt) 45%, var(--surface)));
  cursor: pointer; transition: all 0.2s var(--ease); display: block;
}
.dropzone:hover, .dropzone.dragover {
  border-color: var(--primary); background: var(--primary-soft);
  box-shadow: 0 0 0 4px var(--primary-soft);
}
.dropzone input[type="file"] { display: none; }
.dropzone-icon { font-size: 2.2rem; margin-bottom: 8px; }

.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin: 16px 0; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-size: 0.84rem; font-weight: 700; }
.field input[type="text"], .field input[type="number"], .field input[type="date"],
.field input[type="email"], .field input[type="url"], .field input[type="password"],
.field select, .field textarea {
  width: 100%; padding: 10px 13px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--bg); color: var(--text); font-family: inherit; font-size: 0.92rem;
  transition: border-color 0.16s, box-shadow 0.16s;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft);
}
.actions-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.file-list { list-style: none; padding: 0; margin: 14px 0; display: flex; flex-direction: column; gap: 8px; }
.file-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 13px; border-radius: var(--radius-sm);
  background: var(--surface-alt); border: 1px solid var(--border); font-size: 0.86rem;
}

/* ==================== RESULTS & MONETIZATION ==================== */
.tool-result {
  margin-top: 22px; padding: 20px; border-radius: var(--radius);
  background: var(--surface-alt); border: 1px solid var(--border);
}
.result-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 14px 0; }
.metric-box {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 14px; box-shadow: var(--shadow-xs);
}
.metric-box small { display: block; color: var(--text-muted); font-size: 0.77rem; font-weight: 600; }
.metric-box strong { font-size: 1.22rem; font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; }
.post-offer-banner {
  margin-top: 16px; padding: 14px 16px; border-radius: var(--radius-sm);
  background: var(--primary-soft); border: 1px solid color-mix(in srgb, var(--primary) 30%, transparent);
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
}

/* Hardware Lab widgets */
.kbd-grid { display: flex; flex-direction: column; gap: 6px; overflow-x: auto; padding: 12px; background: var(--surface-alt); border-radius: 12px; border: 1px solid var(--border); }
.kbd-row { display: flex; gap: 5px; }
.kbd-key {
  min-width: 38px; height: 38px; padding: 0 8px; border-radius: 8px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font-size: 0.76rem; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center; transition: all 0.1s; user-select: none;
}
.kbd-key.active { background: var(--primary); color: #fff; border-color: var(--primary); transform: scale(0.95); }
.kbd-key.tested { background: rgba(22, 163, 74, 0.18); border-color: var(--success); color: var(--success); }

/* Sidebar */
.workspace-sidebar { display: flex; flex-direction: column; gap: 16px; }
.offer-card h3, .support-card h3 { margin: 0 0 8px; font-size: 1.04rem; font-weight: 800; }
.offer-card p, .support-card p { margin: 0 0 14px; font-size: 0.87rem; color: var(--text-muted); }

/* Previews & Code */
.preview-box { margin-top: 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px; background: var(--bg); text-align: center; overflow: auto; }
.preview-box img, .preview-box canvas, .preview-box video { max-width: 100%; border-radius: 8px; }
.code-output {
  background: #0b1120; color: #e2e8f0; padding: 14px 16px; border-radius: var(--radius-sm);
  border: 1px solid #1e293b; font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 0.84rem; overflow-x: auto; white-space: pre-wrap; word-break: break-word;
}

/* ==================== COMMAND PALETTE (CTRL+K) & MODALS ==================== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 120;
  background: rgba(7, 11, 20, 0.65); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; padding: 16px;
  animation: fadeIn 0.15s ease;
}
.modal-card {
  width: 100%; max-width: 780px; max-height: 90vh; overflow-y: auto;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 20px; padding: 24px; box-shadow: var(--shadow-lg);
  animation: popUp 0.18s var(--ease);
}
.modal-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 18px; }

.cmdk-card { max-width: 640px; padding: 0; overflow: hidden; }
.cmdk-input-row {
  display: flex; align-items: center; gap: 10px; padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.cmdk-input-row input {
  flex: 1; border: none; background: transparent; color: var(--text);
  font-family: inherit; font-size: 1rem; font-weight: 500; outline: none;
}
.cmdk-list { max-height: 410px; overflow-y: auto; padding: 8px; }
.cmdk-item {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  border-radius: 11px; text-decoration: none; color: var(--text);
  transition: background 0.12s;
}
.cmdk-item:hover, .cmdk-item.is-selected { background: var(--primary-soft); color: var(--primary); }
.cmdk-item-icon {
  width: 34px; height: 34px; border-radius: 9px; background: var(--surface-alt);
  display: grid; place-items: center; font-size: 1.1rem; flex-shrink: 0;
}
.cmdk-item-title { flex: 1; font-size: 0.9rem; font-weight: 600; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmdk-footer {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 16px; border-top: 1px solid var(--border);
  background: var(--surface-alt); font-size: 0.76rem; color: var(--text-muted);
}

.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.price-box {
  background: var(--surface-alt); border: 1px solid var(--border);
  border-radius: 15px; padding: 18px; display: flex; flex-direction: column; gap: 10px;
}
.price-featured { border: 2px solid var(--primary); background: var(--primary-soft); }
.price-box h3 { margin: 4px 0 0; font-size: 1.75rem; font-weight: 800; }
.price-box h3 small { font-size: 0.85rem; color: var(--text-muted); font-weight: 600; }
.price-box p { margin: 0; font-size: 0.84rem; flex: 1; }

/* GDPR / CCPA Cookie Bar */
.cookie-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 95;
  background: var(--surface-glass); backdrop-filter: blur(14px);
  border-top: 1px solid var(--border);
  box-shadow: 0 -8px 28px rgba(15, 23, 42, 0.12); padding: 12px 0;
}
.cookie-bar-inner { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.cookie-bar a { color: var(--primary); font-weight: 700; }

/* Empty, Footer & Toasts */
.empty-state { text-align: center; padding: 56px 16px; }
.footer { border-top: 1px solid var(--border); background: var(--surface); padding: 32px 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 0.87rem; font-weight: 600; transition: color 0.15s; }
.footer-links a:hover { color: var(--primary); }

.toast-stack { position: fixed; right: 20px; bottom: 20px; z-index: 99; display: flex; flex-direction: column; gap: 10px; }
.toast {
  background: #0f172a; color: #fff; padding: 12px 16px; border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg); font-size: 0.88rem; font-weight: 600; max-width: 350px;
  animation: popUp 0.18s var(--ease);
}
.toast-error { background: var(--danger); }
.toast-success { background: var(--success); }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popUp { from { opacity: 0; transform: translateY(8px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }

@media (max-width: 920px) {
  .workspace-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .hero { padding: 32px 0 18px; }
  .search-wrap input { padding: 14px 44px 14px 42px; font-size: 0.94rem; }
  .search-kbd { display: none; }
  .trust-strip { border-radius: 16px; padding: 10px 14px; font-size: 0.77rem; }
  .card { padding: 18px; }
  .tools-grid { grid-template-columns: 1fr; }
  .popular-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ==================== GOTOOLVOLT BRAND MARK & VIRAL SHARE BAR ==================== */
.brand-logo {
  width: 42px; height: 42px; border-radius: 12px;
  background: #091326; overflow: hidden; padding: 0;
  box-shadow: 0 6px 18px -4px rgba(6, 182, 212, 0.42);
}
.brand-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brand-volt {
  background: linear-gradient(135deg, #0ea5e9 0%, var(--volt) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
[data-theme="dark"] .brand-volt {
  background: linear-gradient(135deg, #38bdf8 0%, #a3e635 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero h1 {
  background: linear-gradient(135deg, var(--text) 25%, #2563eb 72%, var(--volt) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.privacy-pill {
  border-color: color-mix(in srgb, var(--volt) 40%, var(--border));
}
.btn-primary {
  background: linear-gradient(135deg, #2563eb 0%, #0284c7 62%, #0891b2 100%);
}
.cat-pill.active {
  background: linear-gradient(135deg, #2563eb 0%, #0284c7 70%, #0891b2 100%);
}

/* Viral 1-Click Share Bar */
.share-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-top: 14px; padding: 11px 14px; border-radius: var(--radius-sm);
  background: var(--surface-alt); border: 1px solid var(--border);
}
.share-bar-label { font-size: 0.8rem; font-weight: 700; color: var(--text-muted); margin-right: 4px; }
.share-btn {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 6px 11px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); text-decoration: none;
  font-family: inherit; font-size: 0.77rem; font-weight: 700; cursor: pointer;
  transition: transform 0.16s var(--ease), border-color 0.16s, background 0.16s, color 0.16s;
}
.share-btn:hover { transform: translateY(-1px); border-color: var(--primary); color: var(--primary); }
.share-btn-wa:hover { border-color: #16a34a; color: #16a34a; background: rgba(22, 163, 74, 0.09); }
.share-btn-x:hover  { border-color: var(--text); color: var(--text); background: var(--surface-alt); }
.share-btn-rd:hover { border-color: #ea580c; color: #ea580c; background: rgba(234, 88, 12, 0.09); }
.share-btn-li:hover { border-color: #0284c7; color: #0284c7; background: rgba(2, 132, 199, 0.09); }

/* ==========================================================================
   GoToolVolt v7.1 — Executive Spacious Home Layout & Mobile Polish
   ========================================================================== */

[data-cat="gaming"]    { --cat-accent: #8b5cf6; --cat-soft: rgba(139, 92, 246, 0.12); }
[data-cat="ecommerce"] { --cat-accent: #059669; --cat-soft: rgba(5, 150, 105, 0.12); }

html, body {
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
}

img, video, canvas, svg {
  max-width: 100%;
}

.workspace pre,
.workspace code {
  overflow-x: auto;
  word-break: break-word;
}

.btn,
.cat-pill,
.suite-pill,
.mode-chip,
.tool-card {
  touch-action: manipulation;
}

/* --- Topbar: crisp single-line alignment on desktop --- */
.topbar-inner {
  min-height: 70px;
  gap: 16px;
}

.topbar-actions {
  gap: 8px;
}

.topbar-actions .btn-sm,
.topbar-actions .topbar-select {
  height: 36px;
  padding: 0 11px;
  font-size: 0.82rem;
  line-height: 1;
}

.topbar-actions .btn-icon {
  width: 36px;
  height: 36px;
}

/* --- Breathable Minimalist Hero (Zero Clutter) --- */
.hero {
  padding: 58px 0 42px;
}

.privacy-pill {
  padding: 7px 16px;
  margin-bottom: 20px;
  font-size: 0.79rem;
  letter-spacing: 0.01em;
}

.hero h1 {
  max-width: 780px;
  margin: 0 auto 16px;
  font-size: clamp(2rem, 4.2vw, 3.15rem);
  line-height: 1.11;
}

.hero-sub {
  max-width: 650px;
  margin: 0 auto 30px;
  font-size: clamp(0.95rem, 1.35vw, 1.05rem);
  line-height: 1.6;
}

.search-wrap {
  max-width: 680px;
  margin: 0 auto 16px;
}

.search-wrap input {
  padding: 16px 96px 16px 48px;
  border-radius: 16px;
  font-size: 0.98rem;
}

.quick-chips {
  margin: 0 auto;
  gap: 8px;
}

.quick-chip {
  padding: 6px 13px;
  font-size: 0.79rem;
}

/* --- Popular Bento Strip: Clean 3x2 Symmetry --- */
.bento-section {
  margin-bottom: 44px;
}

.section-head {
  margin-bottom: 18px;
}

.section-head h2 {
  font-size: 1.18rem;
}

.popular-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.popular-card {
  padding: 18px 20px;
  gap: 14px;
}

/* --- Dedicated Catalog Navigation Dock (6 Suites + Contextual Sub-Categories) --- */
.catalog-nav-panel {
  margin: 8px 0 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.suite-bar {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  padding: 6px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  max-width: 100%;
}

.suite-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 16px;
  border-radius: 13px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s var(--ease);
}

.suite-pill:hover {
  background: var(--surface-alt);
  color: var(--text);
}

.suite-pill.active {
  background: linear-gradient(135deg, #2563eb 0%, #0284c7 68%, #0891b2 100%);
  color: #ffffff;
  box-shadow: 0 6px 16px -4px var(--primary-glow);
}

.suite-pill.active .cat-count {
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  opacity: 1;
}

.category-bar {
  gap: 8px;
  padding-top: 2px;
}

/* --- Catalog Header & Mode Toggle --- */
.catalog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.catalog-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.catalog-header h2 {
  font-size: 1.35rem;
}

.catalog-count-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.mode-filter-group {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 12px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
}

.mode-chip {
  padding: 6px 12px;
  border-radius: 9px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.79rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.16s var(--ease);
}

.mode-chip:hover {
  color: var(--text);
}

.mode-chip.active {
  background: var(--surface);
  color: var(--primary);
  box-shadow: var(--shadow-xs);
}

/* --- Spacious, Symmetric 3-Column Tool Cards --- */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.tool-card, a.tool-card {
  padding: 22px;
  gap: 12px;
  min-height: 188px;
  overflow: hidden;
}

.tool-card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, var(--cat-accent, var(--primary)), transparent);
  opacity: 0;
  transition: opacity 0.2s var(--ease);
}

.tool-card:hover::before {
  opacity: 1;
}

.tool-card h3 {
  font-size: 1rem;
  line-height: 1.32;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tool-card p {
  font-size: 0.85rem;
  line-height: 1.52;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tool-card-footer {
  margin-top: auto;
  padding-top: 10px;
}

/* --- Progressive Load More Bar --- */
.catalog-more-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
  padding-top: 12px;
}

.catalog-more-bar .btn {
  padding: 12px 22px;
  font-size: 0.9rem;
}

/* --- Tablet Breakpoint --- */
@media (max-width: 1024px) {
  .popular-grid,
  .tools-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .workspace-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .workspace-sidebar {
    position: static;
    width: 100%;
  }
}

/* --- Mobile Breakpoint (iPhone / Android) --- */
@media (max-width: 640px) {
  .container {
    padding-left: 14px;
    padding-right: 14px;
  }

  /* Evita zoom automático en Safari iOS solo en móvil */
  .workspace input,
  .workspace select,
  .workspace textarea,
  #globalSearch,
  #proKeyInput {
    font-size: 16px;
  }

  .topbar-inner {
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 0;
  }

  .brand {
    flex: 1 1 auto;
    min-width: 0;
  }

  .brand small {
    display: none;
  }

  .topbar-actions {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: space-between;
  }

  .topbar-actions .btn-sm,
  .topbar-actions .topbar-select {
    height: 38px;
    font-size: 0.82rem;
    padding: 0 9px;
  }

  #headerCta {
    flex: 1 1 100%;
    justify-content: center;
  }

  .hero {
    padding: 28px 0 22px;
  }

  .hero h1 {
    font-size: 1.6rem;
    line-height: 1.18;
  }

  .hero-sub {
    margin-bottom: 20px;
    font-size: 0.92rem;
  }

  .bento-section {
    margin-bottom: 28px;
  }

  .catalog-nav-panel {
    align-items: stretch;
    margin: 4px 0 20px;
  }

  .suite-bar {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 6px;
  }

  .category-bar {
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }

  .suite-bar::-webkit-scrollbar,
  .category-bar::-webkit-scrollbar {
    display: none;
  }

  .suite-pill,
  .cat-pill {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .popular-grid,
  .tools-grid,
  .form-grid,
  .pricing-grid {
    grid-template-columns: 1fr !important;
    gap: 14px;
  }

  .tool-card, a.tool-card {
    min-height: 0;
    padding: 18px;
  }

  .catalog-header {
    gap: 10px;
  }

  .mode-filter-group {
    width: 100%;
    justify-content: space-between;
  }

  .mode-chip {
    flex: 1;
    text-align: center;
  }

  .actions-row,
  .catalog-more-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .actions-row .btn,
  .catalog-more-bar .btn {
    width: 100%;
    min-height: 44px;
    justify-content: center;
  }

  .dropzone {
    padding: 22px 14px;
  }

  .post-offer-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .post-offer-banner .btn {
    width: 100%;
    text-align: center;
  }

  .modal-overlay {
    padding: 10px;
    align-items: flex-end;
  }

  .modal-card {
    max-height: 88dvh;
    overflow-y: auto;
    border-radius: 18px 18px 12px 12px;
    padding: 18px 14px calc(18px + env(safe-area-inset-bottom));
  }

  .cookie-bar {
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
  }

  .cookie-bar-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .footer-links {
    gap: 10px 14px;
  }
}

.lang-auto-banner {
  background: var(--primary-soft);
  border-bottom: 1px solid var(--border);
  padding: 8px 0;
  font-size: 0.84rem;
  font-weight: 600;
}
.lang-auto-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
