title: Light and dark theme for my Maui Blazor app
body: <p>I would like to implement light and dark theme inside of my <strong>Maui Blazor</strong> application. As you know, Blazor is nothing other than Html and Css so I easily implement dark and light theme for the content of my app (thanks to a simple <em>.dark</em> class added on the html tag).</p>
  <p><strong>The problem I am facing is for the upper and lower part of the Maui application.</strong></p>
  <p>Let me show you by an example.</p>
  <p>Android version</p>
  <p><a href="https://i.stack.imgur.com/Wholn.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Wholn.png" alt="enter image description here" /></a></p>
  <p>iOS version</p>
  <p><a href="https://i.stack.imgur.com/cKk9i.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cKk9i.png" alt="enter image description here" /></a></p>
  <p>The pictures above show you the current situation: on the left, the light theme and on the right, the dark theme. As you can see, the dark theme is problematic for the top and bottom sections (only the top section is problematic for the iOS version).</p>
  <p>What I would like to achieve: the top and bottom sections should be colored  the same as the content of the page:</p>
  <ul>
  <li><strong>#292929</strong> for the Dark theme</li>
  <li><strong>#FFFFFF</strong> for the Light theme</li>
  </ul>
  <p>Something like the picture below: when switching to the dark theme, everything is coloured.</p>
  <p><strong>I have no idea how to achieve this for Maui Blazor and I have no experience with Xamarin.</strong></p>
  <p>Can you point me to the right direction please ?</p>
  <p><a href="https://i.stack.imgur.com/0pxtS.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/0pxtS.jpg" alt="enter image description here" /></a></p>
  <p>As you probably know, <em>BlazorWebView</em> enables you to host a Blazor web application right in the .NET MAUI application.</p>
  <p><a href="https://i.stack.imgur.com/zaL5q.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zaL5q.png" alt="enter image description here" /></a></p>