
:root{--blue:#166DF2;--text:#0E2040;--muted:#62738F;--line:#DCE7F6;--card:#fff;--page:#F7FBFF;--navy:#06172F}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif;background:var(--page);color:var(--text);line-height:1.45;-webkit-font-smoothing:antialiased}body.dark{--text:#EEF5FF;--muted:#9FB0C7;--line:#263752;--card:#0E1E35;--page:#081528}a{color:inherit;text-decoration:none}button,input{font:inherit}button{cursor:pointer}img{display:block;max-width:100%}.container{width:min(1180px,calc(100% - 34px));margin:auto}.skip{position:absolute;left:-9999px}.skip:focus{left:12px;top:12px;background:#fff;color:#111;padding:8px 11px;z-index:100}
.site-header{position:sticky;top:0;z-index:50;background:rgba(255,255,255,.96);backdrop-filter:blur(14px);border-bottom:1px solid var(--line)}body.dark .site-header{background:rgba(8,21,40,.96)}.header-inner{height:68px;display:flex;align-items:center;gap:18px}.brand{flex:0 0 auto}.brand img{width:205px;height:auto}.header-search{height:42px;width:min(360px,31vw);display:flex;align-items:center;gap:8px;padding:0 12px;border:1px solid var(--line);border-radius:10px;background:var(--card)}.header-search svg{width:18px;height:18px;fill:none;stroke:#536A8D;stroke-width:2}.header-search input{border:0;outline:0;background:transparent;color:var(--text);width:100%;font-size:12px}.desktop-nav{display:flex;gap:22px;margin-left:auto;font-size:12px;font-weight:750}.desktop-nav a:hover{color:var(--blue)}.theme-toggle,.menu-toggle{width:38px;height:38px;border:1px solid var(--line);border-radius:10px;background:var(--card);color:var(--text)}.theme-toggle .sun{display:none}body.dark .theme-toggle .sun{display:inline}body.dark .theme-toggle .moon{display:none}.menu-toggle{display:none}.mobile-menu{background:var(--card);border-top:1px solid var(--line)}.mobile-menu .container{display:grid;padding:8px 0 14px}.mobile-menu a{padding:10px 0;font-weight:700}.search-results{display:none;position:absolute;top:60px;left:50%;transform:translateX(-50%);width:min(520px,calc(100% - 34px));background:var(--card);border:1px solid var(--line);border-radius:12px;box-shadow:0 16px 38px rgba(15,23,42,.13);padding:6px}.search-results.active{display:block}.search-result{padding:10px 12px;border-bottom:1px solid var(--line)}.search-result:last-child{border-bottom:0}.search-result b{display:block;font-size:12px}.search-result small{font-size:11px;color:var(--muted)}
.hero{text-align:center;padding:60px 0 30px;background:radial-gradient(circle at 50% 0,rgba(22,109,242,.08),transparent 40%)}.hero-badge{display:inline-block;padding:7px 12px;border-radius:999px;background:#EAF3FF;color:var(--blue);font-size:12px;font-weight:800}.hero h1{font-size:clamp(44px,6vw,68px);line-height:.98;letter-spacing:-2.7px;margin:17px 0 10px}.hero h1 span{color:var(--blue)}.hero p{max-width:710px;margin:auto;font-size:18px;color:#31496B}.dark .hero p{color:#BCC9DB}
.section{padding:9px 0}.shell{background:var(--card);border:1px solid var(--line);border-radius:15px;padding:18px 20px;box-shadow:0 8px 24px rgba(31,84,150,.05)}.section-head{margin-bottom:13px}.section-head h2{font-size:28px;letter-spacing:-1px;margin:0 0 3px}.section-head p{font-size:13px;color:var(--muted);margin:0}
.tool-grid{display:grid;grid-template-columns:repeat(8,1fr);gap:8px}.tool-card{border:1px solid var(--line);border-radius:11px;padding:12px 8px;background:var(--card);text-align:center;min-height:158px;transition:.18s}.tool-card:hover{transform:translateY(-2px);box-shadow:0 10px 25px rgba(26,78,145,.09)}.tool-card img{width:52px;height:52px;margin:0 auto 8px}.tool-card h3{font-size:12px;margin:0 0 5px}.tool-card p{font-size:10px;color:var(--muted);margin:0;line-height:1.35}.arrow{width:26px;height:26px;border-radius:50%;display:grid;place-items:center;background:#EAF3FF;color:var(--blue);font-weight:900;margin:9px auto 0}
.category-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:8px}.category-card{display:grid;grid-template-columns:48px 1fr;gap:10px;align-items:center;border:1px solid var(--line);border-radius:11px;padding:10px 12px;background:var(--card)}.category-card img{width:48px;height:48px}.category-card h3{font-size:12px;margin:0 0 5px}.category-card span{font-size:10px;color:var(--blue);font-weight:800}
.benefit-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:24px}.benefit-grid article{padding:4px 10px}.benefit-grid img{width:62px;height:62px;margin-bottom:7px}.benefit-grid h3{font-size:16px;margin:0 0 5px}.benefit-grid p{font-size:13px;color:var(--muted);margin:0;max-width:225px}
.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:22px}.steps article{display:grid;grid-template-columns:56px 1fr;gap:13px;align-items:center}.steps span{width:56px;height:56px;border-radius:50%;display:grid;place-items:center;background:#EAF3FF;color:var(--blue);font-size:28px;font-weight:900}.steps h3{font-size:15px;margin:0 0 4px}.steps p{font-size:13px;color:var(--muted);margin:0}
.faq-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;align-items:start}
.faq-column{display:grid;gap:6px;align-content:start}
#faq details{align-self:start;border:1px solid var(--line);border-radius:8px;padding:0 12px;background:var(--card)}
#faq summary{cursor:pointer;list-style:none;padding:11px 22px 11px 0;font-size:11px;font-weight:800;position:relative}
#faq summary::-webkit-details-marker{display:none}
#faq summary:after{content:"⌄";position:absolute;right:0;top:10px;transition:transform .16s ease}
#faq details[open] summary:after{transform:rotate(180deg)}
#faq details p{font-size:11px;color:var(--muted);margin:0 0 11px;line-height:1.6}
.footer{background:var(--navy);color:#D8E5F6;margin-top:12px;padding:26px 0 20px}.footer-grid{display:grid;grid-template-columns:1.3fr repeat(4,1fr);gap:30px}.footer-logo-panel{display:inline-block;background:#fff;border-radius:12px;padding:7px 11px}.footer-logo-panel img{width:190px}.footer-brand p{font-size:12px;color:#C5D2E4}.footer-brand small{font-size:10px;color:#90A4BF}.footer h3{font-size:11px;color:#fff;margin:0 0 8px}.footer a{display:block;font-size:10px;color:#C6D4E7;margin-bottom:5px}
@media(max-width:1050px){.desktop-nav{display:none}.header-search{margin-left:auto;width:min(480px,48vw)}.menu-toggle{display:block}.tool-grid{grid-template-columns:repeat(4,1fr)}.category-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:700px){.container{width:min(100% - 22px,1180px)}.header-inner{height:auto;min-height:60px;display:grid;grid-template-columns:auto 1fr auto auto;gap:8px;padding:7px 0}.brand img{width:156px}.header-search{grid-column:1/-1;grid-row:2;width:100%;height:40px}.hero{padding:36px 0 22px}.hero h1{font-size:44px}.hero p{font-size:15px}.hero-badge{font-size:10px}.shell{padding:15px 12px}.section-head h2{font-size:22px}.tool-grid{grid-template-columns:repeat(2,1fr)}.tool-card{display:grid;grid-template-columns:44px 1fr 26px;grid-template-rows:auto auto;text-align:left;align-items:center;gap:0 8px;min-height:84px;padding:10px}.tool-card img{grid-row:1/3;width:44px;height:44px;margin:0}.tool-card h3{font-size:11px;margin:0 0 3px}.tool-card p{font-size:9px}.arrow{grid-column:3;grid-row:1/3;margin:0;width:24px;height:24px}.category-grid{grid-template-columns:repeat(2,1fr)}.category-card{display:block;min-height:92px;padding:9px}.category-card img{width:40px;height:40px;margin-bottom:7px}.category-card h3{font-size:10px}.category-card span{font-size:9px}.benefit-grid{grid-template-columns:1fr 1fr;gap:18px 12px}.benefit-grid img{width:52px;height:52px}.benefit-grid h3{font-size:13px}.benefit-grid p{font-size:11px}.steps{grid-template-columns:1fr}.faq-grid{grid-template-columns:1fr}.footer-grid{grid-template-columns:1fr 1fr}.footer-brand{grid-column:1/-1}}


/* Approved SonoFiles logo pair — header + footer only */
.logo-dark{display:none!important}
body.dark .logo-light{display:none!important}
body.dark .logo-dark{display:block!important}

.brand{
  display:flex;
  align-items:center;
  overflow:visible;
}
.brand .logo-light,
.brand .logo-dark{
  width:220px;
  height:auto;
  object-fit:contain;
}

.footer-logo-panel{
  overflow:hidden;
}
.footer-logo-panel .logo-light,
.footer-logo-panel .logo-dark{
  width:220px;
  height:auto;
  object-fit:contain;
}

/* Footer itself is dark, so use the approved dark-mode logo there by default. */
.footer .footer-logo-panel .logo-light{display:none!important}
.footer .footer-logo-panel .logo-dark{display:block!important}

@media(max-width:700px){
  .brand .logo-light,
  .brand .logo-dark{width:168px}
  .footer-logo-panel .logo-light,
  .footer-logo-panel .logo-dark{width:190px}
}


/* Approved footer logo only — border/panel removed */
.footer .footer-logo-panel{
  background:transparent!important;
  border:0!important;
  border-radius:0!important;
  padding:0!important;
  box-shadow:none!important;
  overflow:visible!important;
}
.footer .footer-logo-panel .footer-approved-logo{
  display:block!important;
  width:230px!important;
  max-width:100%!important;
  height:auto!important;
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  object-fit:contain!important;
}
@media(max-width:700px){
  .footer .footer-logo-panel .footer-approved-logo{width:210px!important}
}


/* Mobile header refinement only — everything else unchanged */
@media(max-width:700px){
  .header-inner{
    height:58px!important;
    min-height:58px!important;
    display:flex!important;
    align-items:center!important;
    gap:7px!important;
    padding:6px 0!important;
  }

  .brand{
    flex:0 0 auto!important;
  }

  .brand img{
    width:112px!important;
    height:auto!important;
  }

  .header-search{
    flex:1 1 auto!important;
    width:auto!important;
    min-width:0!important;
    height:38px!important;
    margin:0!important;
    grid-column:auto!important;
    grid-row:auto!important;
    padding:0 9px!important;
    gap:6px!important;
    border-radius:9px!important;
  }

  .header-search svg{
    width:16px!important;
    height:16px!important;
    flex:0 0 auto!important;
  }

  .header-search input{
    min-width:0!important;
    width:100%!important;
    padding:0!important;
    font-size:11px!important;
  }

  .header-search input::placeholder{
    color:#7b8ca5!important;
  }

  .theme-toggle{
    flex:0 0 36px!important;
    width:36px!important;
    height:36px!important;
    margin:0!important;
  }

  .menu-toggle{
    display:none!important;
  }

  .mobile-menu{
    display:none!important;
  }
}

@media(max-width:380px){
  .brand img{
    width:101px!important;
  }

  .header-search{
    height:36px!important;
    padding:0 8px!important;
  }

  .header-search input{
    font-size:10px!important;
  }

  .theme-toggle{
    flex-basis:34px!important;
    width:34px!important;
    height:34px!important;
  }
}


/* Header → trust badge spacing only */
.hero{
  padding-top:12px!important;
}

/* Same tight spacing on mobile */
@media(max-width:700px){
  .hero{
    padding-top:12px!important;
  }
}


/* FINAL APPROVED LIGHT + DARK SONOFILES LOGOS — logo rendering only */
.logo-dark{display:none!important}
body.dark .brand .logo-light{display:none!important}
body.dark .brand .logo-dark{display:block!important}

.brand .final-brand-logo{
  width:220px!important;
  max-width:100%!important;
  height:auto!important;
  object-fit:contain!important;
}

/* Footer logo has no panel/border. */
.footer .footer-logo-panel{
  background:transparent!important;
  border:0!important;
  border-radius:0!important;
  padding:0!important;
  box-shadow:none!important;
  overflow:visible!important;
}
.footer-logo-dark{display:none!important}
body.dark .footer-logo-light{display:none!important}
body.dark .footer-logo-dark{display:block!important}
.footer .final-footer-logo{
  width:230px!important;
  max-width:100%!important;
  height:auto!important;
  object-fit:contain!important;
  border:0!important;
  box-shadow:none!important;
}

/* The footer background is dark in the current design, so use the dark logo there
   even while the main page is in light mode for correct contrast. */
body:not(.dark) .footer .footer-logo-light{display:none!important}
body:not(.dark) .footer .footer-logo-dark{display:block!important}

@media(max-width:700px){
  .brand .final-brand-logo{width:112px!important}
  .footer .final-footer-logo{width:210px!important}
}
@media(max-width:380px){
  .brand .final-brand-logo{width:101px!important}
}

/* Locked hero title update */
.hero h1.hero-title-black{color:#3A4454}
.dark .hero h1.hero-title-black{color:#3A4454}


/* SonoFiles homepage H1 refinement */
.hero h1.hero-title-black{
  color:#3A4454;
  font-size:clamp(42px,5.2vw,64px);
  line-height:1.02;
  letter-spacing:-2.2px;
}
@media (max-width: 900px){
  .hero h1.hero-title-black{
    font-size:clamp(40px,7vw,54px);
    letter-spacing:-1.8px;
  }
}
@media (max-width: 700px){
  .hero h1.hero-title-black{
    font-size:38px;
    line-height:1.06;
    letter-spacing:-1.35px;
  }
}
@media (max-width: 380px){
  .hero h1.hero-title-black{
    font-size:34px;
    letter-spacing:-1.1px;
  }
}
.dark .hero h1.hero-title-black{color:#E5E7EB}


/* Mobile-only automatic category counters + clearer theme icon.
   Desktop layout and styling remain unchanged. */
.category-card{position:relative}
.category-count{display:none}

@media(max-width:700px){
  .category-card .category-count{
    display:inline-flex;
    position:absolute;
    top:8px;
    right:8px;
    align-items:center;
    justify-content:center;
    min-width:38px;
    height:20px;
    padding:0 6px;
    border:1px solid #D7E6FA;
    border-radius:999px;
    background:#F2F7FF;
    color:#166DF2;
    font-size:8px;
    line-height:1;
    font-weight:850;
    white-space:nowrap;
  }
  body.dark .category-card .category-count{
    border-color:#35527A;
    background:#112844;
    color:#8EB9FF;
  }

  /* Use a larger, high-contrast icon on phones without changing desktop. */
  .theme-toggle{
    border-color:#CFE0F6!important;
    background:#F1F7FF!important;
    color:#166DF2!important;
    box-shadow:0 2px 8px rgba(22,109,242,.12)!important;
  }
  .theme-toggle .moon,
  .theme-toggle .sun{display:none!important}
  .theme-toggle::before{
    content:"☾";
    display:block;
    font-size:23px;
    line-height:1;
    font-weight:800;
    transform:translateY(-1px);
  }
  body.dark .theme-toggle{
    border-color:#35527A!important;
    background:#10233D!important;
    color:#FFD76A!important;
    box-shadow:0 2px 10px rgba(0,0,0,.28)!important;
  }
  body.dark .theme-toggle::before{
    content:"☀";
    font-size:19px;
    transform:none;
  }
}
.search-result-link{display:block}
.search-result-link:hover{background:rgba(22,109,242,.06)}

/* Reserve approved logo geometry before decode. */
.brand .final-brand-logo,.footer .final-footer-logo{aspect-ratio:4.9/1;object-fit:contain!important}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,[role="button"]:focus-visible{outline:3px solid var(--blue,#166DF2);outline-offset:3px}

/* Search field: suppress the generic focus-visible ring inside the already bordered search control. */
.header-search input:focus-visible{outline:none!important;outline-offset:0!important}

/* Mobile Popular Tools alignment fix — keep the existing two-column design inside its section. */
@media(max-width:700px){
  #popular-tools .tool-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  #popular-tools .tool-card{
    min-width:0;
    width:100%;
    grid-template-columns:44px minmax(0,1fr) 26px;
    box-sizing:border-box;
  }
  #popular-tools .tool-card h3,
  #popular-tools .tool-card p{
    min-width:0;
    overflow-wrap:break-word;
  }
}
