.tools-directory-page { background: radial-gradient(circle at 50% 0%, rgba(99, 67, 220, .18), transparent 31%), radial-gradient(circle at 89% 50%, rgba(29, 91, 185, .11), transparent 26%), linear-gradient(180deg, #020615, #04091a 65%, #061027); }
.agents-directory-page { background: radial-gradient(circle at 48% 0%, rgba(129, 61, 227, .24), transparent 32%), radial-gradient(circle at 88% 48%, rgba(43, 81, 204, .14), transparent 28%), linear-gradient(180deg, #020615, #04091a 65%, #071027); }
.tools-directory-content { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 31px 0 70px; }
.tools-directory-hero { padding: 42px 0 25px; text-align: center; }
.tools-directory-hero .eyebrow { margin: 0 0 9px; color: #9c7cff; font-size: 11px; font-weight: 750; letter-spacing: .15em; text-transform: uppercase; }
.tools-directory-hero h1 { margin: 0; font-size: clamp(32px, 4.3vw, 48px); letter-spacing: -1.4px; }
.tools-directory-hero > p:last-child { margin: 11px 0 0; color: #a7adc3; font-size: 14px; }

/* Tools directory: simple category rows with Home-style tool tiles. */
.tools-browser { margin-top: 3px; }
.tools-search-shell { width: min(560px, 100%); min-height: 50px; margin: 0 auto; padding: 0 16px; display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; align-items: center; gap: 11px; border: 1px solid rgba(108, 119, 158, .28); border-radius: 12px; background: rgba(18, 24, 39, .88); box-shadow: inset 0 1px 0 rgba(255,255,255,.025); }
.tools-search-shell:focus-within { border-color: rgba(151, 119, 255, .72); box-shadow: 0 0 0 3px rgba(127, 86, 239, .09); }
.tools-search-shell > svg { width: 19px; height: 19px; color: #8991a9; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.tools-search-shell input { min-width: 0; height: 48px; color: #f0f2ff; border: 0; outline: 0; background: transparent; font: inherit; font-size: 14px; }
.tools-search-shell input::placeholder { color: #838ca8; }
.tools-search-shell > span { color: #9f90dc; font-size: 10px; white-space: nowrap; }
.tool-categories { margin-top: 40px; display: grid; gap: 32px; }
.tool-category { min-width: 0; }
.tool-category-heading { margin: 0 0 12px; display: flex; align-items: baseline; gap: 9px; }
.tool-category-marker { width: 4px; height: 17px; align-self: center; border-radius: 999px; background: linear-gradient(180deg, #8e64ff, #5a8dff); box-shadow: 0 0 10px rgba(124, 93, 255, .45); }
.tool-category-heading h2 { margin: 0; color: #f2f4ff; font-size: 15px; line-height: 1.2; }
.tool-category-heading p { margin: 0; color: #8992ac; font-size: 11px; }
.tool-category-heading p::before { margin-right: 7px; color: #59627c; content: "—"; }
.tools-browser .tools-directory-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 145px)); justify-content: start; gap: 10px; }
.tools-browser .directory-tool-card { min-width: 0; min-height: 112px; padding: 15px 10px 13px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; color: inherit; border: 1px solid rgba(86, 102, 151, .25); border-radius: 11px; background: linear-gradient(145deg, rgba(21, 30, 56, .94), rgba(12, 20, 42, .92)); box-shadow: inset 0 1px 0 rgba(255,255,255,.022); text-align: center; transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease; }
.tools-browser .directory-tool-card:hover { transform: translateY(-2px); border-color: rgba(127, 101, 235, .6); background: linear-gradient(145deg, rgba(27, 37, 69, .97), rgba(14, 23, 49, .95)); box-shadow: 0 8px 22px rgba(4, 7, 20, .24), 0 0 16px rgba(105, 71, 219, .07); }
.tools-browser .directory-tool-card:focus-visible { outline: 2px solid #9e7aff; outline-offset: 2px; }
.tools-browser .directory-tool-icon { width: 34px; height: 34px; display: grid; place-items: center; color: #c5c7ff; }
.tools-browser .directory-tool-icon svg { width: 27px; height: 27px; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; }
.tools-browser .directory-base64-icon { font-size: 22px; font-weight: 800; line-height: 1; }
.tools-browser .directory-tool-icon.green { color: #4fe080; }.tools-browser .directory-tool-icon.blue { color: #5d8dff; }.tools-browser .directory-tool-icon.purple { color: #a15aff; }.tools-browser .directory-tool-icon.orange { color: #f7a72d; }.tools-browser .directory-tool-icon.coral { color: #ff5575; }.tools-browser .directory-tool-icon.silver { color: #c9cbe0; }.tools-browser .directory-tool-icon.lilac { color: #beb0ff; }
.tools-browser .directory-tool-icon.postal-directory-icon { color: #a78bfa; }
.tools-browser .directory-tool-icon.postal-directory-icon svg { width: 29px; height: 29px; stroke-width: 1.65; }
.tools-browser .directory-tool-card > strong { max-width: 100%; color: #f0f2fc; font-size: 12px; font-weight: 600; line-height: 1.45; }
.tools-empty-state { min-height: 230px; margin-top: 34px; padding: 40px 24px; display: grid; place-items: center; align-content: center; text-align: center; border: 1px dashed rgba(117, 100, 207, .28); border-radius: 12px; background: rgba(9, 15, 34, .48); }
.tools-empty-state > svg { width: 30px; height: 30px; color: #9f83f3; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.tools-empty-state h2 { margin: 12px 0 0; font-size: 17px; }.tools-empty-state p { margin: 6px 0 17px; color: #8f97af; font-size: 12px; }
.tools-empty-state button { padding: 8px 13px; color: #dcd5ff; border: 1px solid rgba(141, 111, 238, .48); border-radius: 9px; background: rgba(113, 76, 219, .12); font: inherit; font-size: 11px; cursor: pointer; }

/* Preserve the existing larger AI Agent directory cards. */
.tools-directory-section + .tools-directory-section { margin-top: 34px; }
.tools-directory-heading { margin-bottom: 15px; display: flex; align-items: flex-end; justify-content: space-between; }
.tools-directory-heading h2 { margin: 0; font-size: 19px; }.tools-directory-heading p { margin: 5px 0 0; color: #8e95ab; font-size: 12px; }
.tools-directory-heading > span { padding: 5px 10px; color: #bdb1ff; border: 1px solid rgba(135, 105, 236, .28); border-radius: 999px; background: rgba(113, 76, 219, .09); font-size: 10px; }
.tools-directory-section .tools-directory-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.tools-directory-section .directory-tool-card { min-height: 116px; padding: 20px; display: grid; grid-template-columns: 58px minmax(0, 1fr) auto; align-items: center; gap: 17px; border: 1px solid rgba(97, 110, 151, .2); border-radius: 13px; background: linear-gradient(145deg, rgba(22, 31, 55, .92), rgba(10, 18, 38, .9)); box-shadow: inset 0 1px 0 rgba(255,255,255,.025); transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.tools-directory-section .directory-tool-card:hover { transform: translateY(-3px); border-color: rgba(118, 99, 235, .55); background: linear-gradient(145deg, rgba(28, 37, 67, .96), rgba(13, 22, 47, .94)); }
.tools-directory-section .directory-tool-icon { width: 58px; height: 58px; display: grid; place-items: center; color: #c5c7ff; border-radius: 12px; background: rgba(87, 72, 182, .15); font-size: 29px; font-weight: 650; }
.tools-directory-section .directory-tool-icon.green { color: #48d67b; }.tools-directory-section .directory-tool-icon.blue { color: #4f83ff; }.tools-directory-section .directory-tool-icon.purple { color: #9b51f5; }.tools-directory-section .directory-tool-icon.orange { color: #f3a437; }
.tools-directory-section .directory-tool-card h3 { margin: 0; font-size: 15px; }.tools-directory-section .directory-tool-card p { margin: 7px 0 0; color: #9da4b9; font-size: 12px; line-height: 1.55; }.tools-directory-section .directory-tool-arrow { color: #a891ff; font-size: 22px; }

@media (max-width: 920px) {
  .tools-browser .tools-directory-grid { grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); }
  .tools-directory-section .tools-directory-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .tools-directory-content { width: min(100% - 24px, 1180px); padding-top: 22px; }.tools-directory-hero { padding: 32px 0 22px; }.tools-directory-hero h1 { font-size: 30px; }
  .tools-search-shell { min-height: 48px; padding: 0 13px; grid-template-columns: 18px minmax(0, 1fr); }.tools-search-shell input { height: 46px; }.tools-search-shell > span { display: none; }
  .tool-categories { margin-top: 31px; gap: 29px; }.tool-category-heading { align-items: flex-start; flex-wrap: wrap; gap: 5px 8px; }.tool-category-heading p { flex-basis: calc(100% - 12px); margin-left: 12px; }.tool-category-heading p::before { display: none; }
  .tools-browser .tools-directory-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }.tools-browser .directory-tool-card { min-height: 105px; }
  .tools-directory-section .directory-tool-card { min-height: 104px; padding: 15px; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 13px; }.tools-directory-section .directory-tool-icon { width: 48px; height: 48px; font-size: 24px; }
}
@media (prefers-reduced-motion: reduce) { .directory-tool-card { transition: none; } }
