/* ============ Reset & Base ============ */
    *, *::before, *::after { box-sizing: border-box; }
    html, body { margin: 0; padding: 0; }
    :root {
      --bg: #0a0a0b;
      --bg-soft: #111114;
      --bg-card: #141418;
      --bg-card-hover: #1a1a20;
      --border: rgba(255, 255, 255, 0.08);
      --border-strong: rgba(255, 255, 255, 0.14);
      --text: #f5f5f7;
      --text-soft: #b4b4b8;
      --text-muted: #6e6e76;
      --accent: #8b5cf6;
      --accent-2: #ec4899;
      --accent-3: #06b6d4;
      --grad-1: linear-gradient(135deg, #8b5cf6 0%, #ec4899 100%);
      --grad-2: linear-gradient(135deg, #06b6d4 0%, #8b5cf6 100%);
      --grad-3: linear-gradient(135deg, #f59e0b 0%, #ec4899 100%);
      --shadow: 0 1px 2px rgba(0,0,0,0.4), 0 8px 24px rgba(0,0,0,0.35);
      --radius: 14px;
      --radius-lg: 22px;
    }
    body {
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
      background: var(--bg);
      color: var(--text);
      line-height: 1.5;
      -webkit-font-smoothing: antialiased;
      -moz-osx-font-smoothing: grayscale;
      min-height: 100vh;
      overflow-x: hidden;
    }
    a { color: inherit; text-decoration: none; }
    button { font-family: inherit; cursor: pointer; }

    /* ============ Background ambient glow ============ */
    .ambient {
      position: fixed;
      inset: 0;
      pointer-events: none;
      z-index: 0;
      overflow: hidden;
    }
    .ambient::before,
    .ambient::after {
      content: "";
      position: absolute;
      border-radius: 50%;
      filter: blur(120px);
      opacity: 0.35;
    }
    .ambient::before {
      width: 600px; height: 600px;
      background: var(--accent);
      top: -200px; left: -200px;
    }
    .ambient::after {
      width: 500px; height: 500px;
      background: var(--accent-2);
      bottom: -150px; right: -150px;
    }

    /* ============ Layout ============ */
    .container {
      max-width: 1200px;
      margin: 0 auto;
      padding: 0 24px;
      position: relative;
      z-index: 1;
    }

    /* ============ Nav ============ */
    nav {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 20px 0;
    }
    .logo {
      display: flex;
      align-items: center;
      gap: 10px;
      font-weight: 700;
      font-size: 18px;
      letter-spacing: -0.01em;
    }
    .logo-mark {
      width: 30px; height: 30px;
      border-radius: 8px;
      background: var(--grad-1);
      display: grid; place-items: center;
      color: white; font-size: 16px;
      box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
    }
    .nav-links {
      display: flex; gap: 28px;
      font-size: 14px;
      color: var(--text-soft);
    }
    .nav-links a:hover { color: var(--text); }
    .nav-cta {
      padding: 8px 16px;
      border-radius: 999px;
      background: rgba(255,255,255,0.06);
      border: 1px solid var(--border);
      font-size: 13px;
      color: var(--text);
      transition: all 0.2s;
    }
    .nav-cta:hover { background: rgba(255,255,255,0.1); border-color: var(--border-strong); }

    /* ============ Hero ============ */
    .hero {
      text-align: center;
      padding: 80px 0 40px;
    }
    .badge {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      padding: 6px 14px;
      border-radius: 999px;
      background: rgba(255,255,255,0.04);
      border: 1px solid var(--border);
      font-size: 13px;
      color: var(--text-soft);
      margin-bottom: 28px;
    }
    .badge .dot {
      width: 6px; height: 6px; border-radius: 50%;
      background: #10b981;
      box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
    }
    h1 {
      font-size: clamp(40px, 6vw, 76px);
      line-height: 1.05;
      letter-spacing: -0.035em;
      font-weight: 700;
      margin: 0 0 24px;
    }
    h1 .serif {
      font-family: 'Instrument Serif', serif;
      font-style: italic;
      font-weight: 400;
      background: var(--grad-1);
      -webkit-background-clip: text;
      background-clip: text;
      -webkit-text-fill-color: transparent;
    }
    .subtitle {
      font-size: clamp(16px, 1.5vw, 19px);
      color: var(--text-soft);
      max-width: 640px;
      margin: 0 auto 48px;
      line-height: 1.6;
    }

    /* ============ Search ============ */
    .search-wrap {
      max-width: 720px;
      margin: 0 auto;
      position: relative;
    }
    .search-box {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 8px 8px 8px 22px;
      background: rgba(20, 20, 24, 0.7);
      border: 1px solid var(--border-strong);
      border-radius: 999px;
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      box-shadow: var(--shadow);
      transition: all 0.2s;
    }
    .search-box:focus-within {
      border-color: rgba(139, 92, 246, 0.5);
      box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1), var(--shadow);
    }
    .search-icon {
      color: var(--text-muted);
      flex-shrink: 0;
    }
    #searchInput {
      flex: 1;
      background: transparent;
      border: none;
      outline: none;
      color: var(--text);
      font-size: 16px;
      padding: 14px 0;
      font-family: inherit;
    }
    #searchInput::placeholder {
      color: var(--text-muted);
    }
    .search-btn {
      padding: 12px 22px;
      border-radius: 999px;
      background: var(--grad-1);
      color: white;
      border: none;
      font-weight: 600;
      font-size: 14px;
      transition: transform 0.15s, box-shadow 0.2s;
      white-space: nowrap;
    }
    .search-btn:hover {
      transform: translateY(-1px);
      box-shadow: 0 8px 20px rgba(139, 92, 246, 0.4);
    }

    /* Suggestions */
    .suggestions {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 8px;
      margin-top: 24px;
    }
    .suggestion-chip {
      padding: 7px 14px;
      border-radius: 999px;
      background: rgba(255,255,255,0.04);
      border: 1px solid var(--border);
      font-size: 13px;
      color: var(--text-soft);
      transition: all 0.15s;
    }
    .suggestion-chip:hover {
      background: rgba(255,255,255,0.08);
      color: var(--text);
      border-color: var(--border-strong);
    }
    .suggestions-label {
      width: 100%;
      text-align: center;
      color: var(--text-muted);
      font-size: 12px;
      margin-bottom: 4px;
    }

    /* ============ Categories ============ */
    .categories {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
      justify-content: center;
      margin: 56px 0 28px;
    }
    .cat-pill {
      padding: 8px 16px;
      border-radius: 999px;
      background: rgba(255,255,255,0.04);
      border: 1px solid var(--border);
      font-size: 13px;
      color: var(--text-soft);
      transition: all 0.15s;
      display: inline-flex;
      align-items: center;
      gap: 6px;
    }
    .cat-pill:hover {
      background: rgba(255,255,255,0.08);
      color: var(--text);
    }
    .cat-pill.active {
      background: var(--text);
      color: #000;
      border-color: var(--text);
    }
    .cat-pill .count {
      font-size: 11px;
      padding: 1px 7px;
      border-radius: 999px;
      background: rgba(0,0,0,0.15);
      opacity: 0.7;
    }
    .cat-pill.active .count {
      background: rgba(255,255,255,0.2);
      color: #fff;
      opacity: 1;
    }

    /* ============ Results / Section ============ */
    .section { margin-bottom: 60px; }
    .section-header {
      display: flex;
      align-items: baseline;
      justify-content: space-between;
      margin-bottom: 24px;
    }
    .section-title {
      font-size: 22px;
      font-weight: 600;
      letter-spacing: -0.02em;
      display: flex;
      align-items: center;
      gap: 10px;
    }
    .section-title .accent-bar {
      width: 3px;
      height: 18px;
      border-radius: 2px;
      background: var(--grad-1);
    }
    .section-meta {
      font-size: 13px;
      color: var(--text-muted);
    }
    .empty-state {
      text-align: center;
      padding: 60px 20px;
      color: var(--text-muted);
    }
    .empty-state .icon {
      font-size: 40px;
      margin-bottom: 12px;
      opacity: 0.6;
    }

    /* ============ Tool Grid ============ */
    .tools-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
      gap: 16px;
    }
    .tool-card {
      display: flex;
      flex-direction: column;
      padding: 22px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      transition: all 0.2s ease;
      position: relative;
      overflow: hidden;
      text-decoration: none;
      color: inherit;
    }
    .tool-card::before {
      content: "";
      position: absolute;
      top: 0; left: 0; right: 0;
      height: 1px;
      background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
      opacity: 0;
      transition: opacity 0.2s;
    }
    .tool-card:hover {
      background: var(--bg-card-hover);
      border-color: var(--border-strong);
      transform: translateY(-2px);
      box-shadow: 0 8px 24px rgba(0,0,0,0.4);
    }
    .tool-card:hover::before { opacity: 1; }
    .tool-card:hover .arrow {
      transform: translate(2px, -2px);
      opacity: 1;
    }

    .tool-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      margin-bottom: 14px;
    }
    .tool-icon {
      width: 44px; height: 44px;
      border-radius: 11px;
      display: grid; place-items: center;
      font-size: 22px;
      background: rgba(255,255,255,0.05);
      border: 1px solid var(--border);
    }
    .arrow {
      color: var(--text-muted);
      transition: all 0.2s;
      opacity: 0.6;
    }
    .tool-name {
      font-size: 16px;
      font-weight: 600;
      letter-spacing: -0.01em;
      margin: 0 0 6px;
      display: flex;
      align-items: center;
      gap: 8px;
    }
    .tool-name .badge-new {
      font-size: 10px;
      padding: 2px 6px;
      border-radius: 4px;
      background: rgba(139, 92, 246, 0.2);
      color: #c4b5fd;
      font-weight: 500;
      text-transform: uppercase;
      letter-spacing: 0.05em;
    }
    .tool-desc {
      font-size: 14px;
      color: var(--text-soft);
      line-height: 1.55;
      margin: 0 0 16px;
      flex: 1;
    }
    .tool-tags {
      display: flex;
      flex-wrap: wrap;
      gap: 6px;
    }
    .tool-tag {
      font-size: 11px;
      padding: 3px 8px;
      border-radius: 6px;
      background: rgba(255,255,255,0.04);
      color: var(--text-muted);
      border: 1px solid var(--border);
    }
    .tool-tag.highlight {
      background: rgba(139, 92, 246, 0.15);
      color: #c4b5fd;
      border-color: rgba(139, 92, 246, 0.3);
    }

    /* Color variants for category accent on icon */
    .tool-icon.cat-writing { background: linear-gradient(135deg, rgba(139,92,246,0.2), rgba(236,72,153,0.15)); border-color: rgba(139,92,246,0.3); }
    .tool-icon.cat-image { background: linear-gradient(135deg, rgba(236,72,153,0.2), rgba(245,158,11,0.15)); border-color: rgba(236,72,153,0.3); }
    .tool-icon.cat-pdf { background: linear-gradient(135deg, rgba(239,68,68,0.2), rgba(245,158,11,0.15)); border-color: rgba(239,68,68,0.3); }
    .tool-icon.cat-productivity { background: linear-gradient(135deg, rgba(6,182,212,0.2), rgba(16,185,129,0.15)); border-color: rgba(6,182,212,0.3); }
    .tool-icon.cat-research { background: linear-gradient(135deg, rgba(59,130,246,0.2), rgba(139,92,246,0.15)); border-color: rgba(59,130,246,0.3); }
    .tool-icon.cat-business { background: linear-gradient(135deg, rgba(16,185,129,0.2), rgba(6,182,212,0.15)); border-color: rgba(16,185,129,0.3); }
    .tool-icon.cat-daily { background: linear-gradient(135deg, rgba(245,158,11,0.2), rgba(236,72,153,0.15)); border-color: rgba(245,158,11,0.3); }
    .tool-icon.cat-finance { background: linear-gradient(135deg, rgba(16,185,129,0.2), rgba(59,130,246,0.15)); border-color: rgba(16,185,129,0.3); }

    /* Top match highlight */
    .tool-card.top-match {
      border-color: rgba(139, 92, 246, 0.4);
      background: linear-gradient(180deg, rgba(139, 92, 246, 0.08), var(--bg-card));
    }

    /* ============ Editorial layer ============ */
    .cat-intro {
      font-size: 15px;
      line-height: 1.65;
      color: var(--text-soft);
      max-width: 780px;
      margin: -8px 0 24px;
      padding-left: 14px;
      border-left: 2px solid rgba(139, 92, 246, 0.35);
    }

    .badge-pick {
      font-size: 10px;
      padding: 2px 7px;
      border-radius: 4px;
      background: rgba(236, 72, 153, 0.18);
      color: #f9a8d4;
      font-weight: 500;
      text-transform: uppercase;
      letter-spacing: 0.05em;
      white-space: nowrap;
    }
    .tool-card.is-pick { border-color: rgba(236, 72, 153, 0.28); }

    .tool-card-main {
      display: flex;
      flex-direction: column;
      flex: 1;
      color: inherit;
      text-decoration: none;
    }
    .tool-review {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      margin-top: 14px;
      padding-top: 12px;
      border-top: 1px solid var(--border);
      font-size: 12px;
      font-weight: 500;
      color: #c4b5fd;
      transition: color 0.15s;
    }
    .tool-review:hover { color: #ddd6fe; }

    .tool-editorial {
      margin: 0 0 16px;
      padding: 12px 14px;
      border-radius: 10px;
      background: rgba(255,255,255,0.03);
      border: 1px solid var(--border);
    }
    .ed-row {
      display: flex;
      gap: 8px;
      align-items: baseline;
      font-size: 13px;
      margin-bottom: 6px;
    }
    .ed-label {
      font-size: 11px;
      text-transform: uppercase;
      letter-spacing: 0.06em;
      color: var(--text-muted);
      flex-shrink: 0;
    }
    .ed-val { color: var(--text); font-weight: 500; }
    .ed-note {
      font-size: 13px;
      line-height: 1.55;
      color: var(--text-soft);
      font-style: italic;
    }

    /* Head-to-head comparison */
    .compare {
      background: var(--bg-soft);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 20px 22px;
      margin-bottom: 24px;
    }
    .compare-head {
      display: flex;
      align-items: baseline;
      gap: 10px;
      flex-wrap: wrap;
      margin-bottom: 14px;
    }
    .compare-eyebrow {
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 0.12em;
      color: var(--text-muted);
      padding: 3px 8px;
      border-radius: 5px;
      background: rgba(255,255,255,0.05);
      border: 1px solid var(--border);
    }
    .compare-title { font-size: 15px; font-weight: 600; color: var(--text); }
    .compare-rows { display: flex; flex-direction: column; }
    .compare-row {
      display: flex;
      gap: 16px;
      align-items: flex-start;
      padding: 10px 0;
      border-top: 1px solid var(--border);
      flex-wrap: wrap;
    }
    .compare-row:first-child { border-top: none; }
    .compare-scenario {
      flex: 1 1 260px;
      font-size: 13px;
      color: var(--text-soft);
      line-height: 1.5;
    }
    .compare-pick { flex: 1 1 300px; display: flex; flex-direction: column; gap: 2px; }
    .pick-name {
      font-size: 13px;
      font-weight: 600;
      background: var(--grad-1);
      -webkit-background-clip: text;
      background-clip: text;
      -webkit-text-fill-color: transparent;
    }
    .pick-why { font-size: 12px; color: var(--text-muted); line-height: 1.5; }
    @media (max-width: 768px) {
      .compare-row { flex-direction: column; gap: 6px; }
      .cat-intro { font-size: 14px; }
    }

    /* ============ Featured / Stats strip ============ */
    .stats {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 20px;
      padding: 32px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius-lg);
      margin: 40px 0;
    }
    .stat-num {
      font-size: 32px;
      font-weight: 700;
      letter-spacing: -0.02em;
      background: var(--grad-1);
      -webkit-background-clip: text;
      background-clip: text;
      -webkit-text-fill-color: transparent;
    }
    .stat-label {
      font-size: 13px;
      color: var(--text-muted);
      margin-top: 4px;
    }

    /* ============ Footer ============ */
    footer {
      padding: 50px 0 40px;
      border-top: 1px solid var(--border);
      margin-top: 60px;
      color: var(--text-muted);
      font-size: 13px;
      text-align: center;
    }
    .footer-nav {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 8px 22px;
      margin-bottom: 18px;
    }
    .footer-nav a {
      color: var(--text-soft);
      font-size: 13px;
      transition: color 0.15s;
      position: relative;
    }
    .footer-nav a:hover { color: var(--text); }
    .footer-nav a::after {
      content: "";
      position: absolute;
      left: 0; right: 0; bottom: -4px;
      height: 1px;
      background: var(--grad-1);
      transform: scaleX(0);
      transform-origin: center;
      transition: transform 0.2s;
    }
    .footer-nav a:hover::after { transform: scaleX(1); }
    .footer-copy .heart { color: var(--accent-2); }

    /* ============ Responsive ============ */
    @media (max-width: 768px) {
      .nav-links { display: none; }
      .hero { padding: 50px 0 30px; }
      .stats { grid-template-columns: repeat(2, 1fr); padding: 24px; }
      .search-box { padding: 6px 6px 6px 16px; }
      .search-btn { padding: 10px 16px; font-size: 13px; }
      .tools-grid { grid-template-columns: 1fr; }
    }

    /* Subtle fade-in for cards */
    @keyframes fadeUp {
      from { opacity: 0; transform: translateY(8px); }
      to { opacity: 1; transform: translateY(0); }
    }
    .tool-card { animation: fadeUp 0.35s ease backwards; }

    /* ============ Guides preview ============ */
    .guides-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
      gap: 16px;
    }
    .guide-card {
      display: flex;
      flex-direction: column;
      padding: 24px;
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      transition: all 0.2s;
      text-decoration: none;
      color: inherit;
    }
    .guide-card:hover {
      background: var(--bg-card-hover);
      border-color: var(--border-strong);
      transform: translateY(-2px);
    }
    .guide-card .guide-eyebrow {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      font-size: 11px;
      text-transform: uppercase;
      letter-spacing: 0.1em;
      color: var(--text-muted);
      margin-bottom: 10px;
    }
    .guide-card .guide-eyebrow .dot {
      width: 5px; height: 5px; border-radius: 50%;
      background: var(--grad-1);
    }
    .guide-card h3 {
      font-size: 17px;
      font-weight: 600;
      letter-spacing: -0.015em;
      margin: 0 0 8px;
      line-height: 1.35;
    }
    .guide-card p {
      font-size: 14px;
      color: var(--text-soft);
      line-height: 1.55;
      margin: 0 0 16px;
      flex: 1;
    }
    .guide-card .guide-meta {
      display: flex;
      align-items: center;
      justify-content: space-between;
      font-size: 12px;
      color: var(--text-muted);
    }
    .guide-card .read-more {
      color: #c4b5fd;
      font-weight: 500;
    }
    .see-all {
      text-align: center;
      margin-top: 24px;
    }
    .see-all a {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      color: var(--text-soft);
      font-size: 14px;
      padding: 10px 20px;
      border-radius: 999px;
      background: rgba(255,255,255,0.04);
      border: 1px solid var(--border);
      transition: all 0.15s;
    }
    .see-all a:hover {
      background: rgba(255,255,255,0.08);
      color: var(--text);
      border-color: var(--border-strong);
    }
    @media (max-width: 768px) {
      .guides-grid { grid-template-columns: 1fr; }
    }
      /* AdSense slot wrapper */
    .ad-slot{margin:30px 0;text-align:center}
    .ad-slot .ad-label{display:block;font-size:10px;text-transform:uppercase;letter-spacing:.12em;color:var(--text-muted);margin-bottom:10px}

    /* Sponsored placement */
    .promo-card {
      position: relative;
      display: block;
      margin: 0 0 36px;
      padding: 22px 24px;
      border-radius: var(--radius-lg);
      border: 1px solid rgba(139, 92, 246, 0.28);
      background:
        radial-gradient(620px 130px at 12% 0%, rgba(139, 92, 246, 0.14), transparent 70%),
        var(--bg-card);
      transition: border-color 0.18s, transform 0.18s;
    }
    .promo-card:hover { border-color: rgba(139, 92, 246, 0.5); transform: translateY(-2px); }
    .promo-tag {
      position: absolute;
      top: 12px;
      right: 14px;
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 0.1em;
      color: var(--text-muted);
      padding: 2px 7px;
      border-radius: 4px;
      border: 1px solid var(--border);
      background: rgba(255,255,255,0.04);
    }
    .promo-body { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
    .promo-icon {
      width: 46px;
      height: 46px;
      flex-shrink: 0;
      border-radius: 12px;
      display: grid;
      place-items: center;
      font-size: 22px;
      background: linear-gradient(135deg, rgba(139, 92, 246, 0.22), rgba(236, 72, 153, 0.18));
      border: 1px solid rgba(139, 92, 246, 0.3);
    }
    .promo-text { flex: 1 1 280px; min-width: 0; display: block; }
    .promo-title { display: block; font-size: 17px; font-weight: 600; margin: 0 0 4px; letter-spacing: -0.01em; }
    .promo-desc { display: block; font-size: 14px; color: var(--text-soft); margin: 0; line-height: 1.55; }
    .promo-cta {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      flex-shrink: 0;
      font-size: 13px;
      font-weight: 600;
      padding: 10px 18px;
      border-radius: 999px;
      background: var(--grad-1);
      color: #fff;
      white-space: nowrap;
    }
    @media (max-width: 640px) {
      .promo-card { padding: 20px 18px; }
      .promo-cta { width: 100%; justify-content: center; margin-top: 4px; }
    }
