    :root {
      --bg-color: #fff;
      --text-color: #333;
      --border-color: #ddd;
      --button-bg: #4CAF50;
      --button-text: white;
      --input-bg: white;
      --input-border: #ccc;
      --table-header-bg: #f2f2f2;
      --table-row-hover-bg: #f5f5f5;
      --compact-padding: 10px;
      --compact-margin: 10px;
      --compact-font-size: 14px;
    }

    body {
      font-family: Arial, sans-serif;
      line-height: 1.6;
      margin: 0;
      padding: 20px;
      transition: background-color 0.3s, color 0.3s;
      background-color: var(--bg-color);
      color: var(--text-color);
      font-size: var(--compact-font-size);
    }

    .container {
      max-width: 800px;
      margin: 0 auto;
      padding: var(--compact-padding);
    }

    h1,
    h2 {
      color: var(--text-color);
    }

    h1 {
      font-size: 24px;
      margin-bottom: var(--compact-margin);
      text-align: center; /* Centralizar título principal */
    }

    h2 {
      font-size: 20px;
      margin-top: calc(var(--compact-margin) * 2); /* Mais espaço antes do título da categoria */
      margin-bottom: var(--compact-margin);
      border-bottom: 1px solid var(--border-color); /* Linha separadora para categoria */
      padding-bottom: 5px;
    }

    .table-wrapper {
      overflow-x: auto; /* Allows horizontal scrolling for the table */
      margin-top: var(--compact-margin);
      margin-bottom: var(--compact-margin);
    }

    table {
      width: 100%;
      border-collapse: collapse;
      table-layout: auto; /* Let browser decide column widths, needed with nowrap */
    }

    th,
    td {
      border: 1px solid var(--border-color);
      padding: 8px;
      text-align: left;
      vertical-align: middle; /* Alinhar conteúdo verticalmente */
      white-space: nowrap; /* Prevent text wrapping in all cells */
    }

    th {
      background-color: var(--table-header-bg);
      font-weight: bold;
    }

    /* Adjust column widths if needed, but 'auto' is often best with nowrap */
    td:first-child { /* Coluna do Logo */
      width: 80px; /* Largura fixa para logo */
      text-align: center;
    }

    td:nth-child(2) { /* Coluna do Nome */ }
    td:nth-child(3) { /* Coluna do Link */ }

    tbody tr {
      transition: background-color 0.2s ease-in-out; /* Smooth transition for hover */
    }

    tbody tr:hover {
      background-color: var(--table-row-hover-bg); /* Use variable for light mode hover */
    }

    img {
      max-width: 60px;
      max-height: 30px;
      display: block;
      margin: 0 auto;
      vertical-align: middle;
    }

    .button {
      background-color: var(--button-bg);
      border: none;
      color: var(--button-text);
      text-align: center;
      text-decoration: none;
      display: inline-block;
      cursor: pointer;
      border-radius: 4px;
      transition: background-color 0.3s, transform 0.2s; /* Add transitions */
    }
    .button:hover {
       /* Optional: slightly darker/lighter background on hover */
       filter: brightness(95%);
    }
     .button:active {
        transform: scale(0.98); /* Slight shrink effect on click */
     }

    .compact-button {
      padding: 6px 12px;
      font-size: var(--compact-font-size);
    }

    .dark-mode {
      --bg-color: #2a2a2a;
      --text-color: #e0e0e0;
      --border-color: #555;
      --button-bg: #555;
      --button-text: #fff;
      --input-bg: #444;
      --input-border: #555;
      --table-header-bg: #444;
      --table-row-hover-bg: #383838;
    }

    .dark-mode a {
      color: #8ab4f8;
    }
    .dark-mode a:visited {
      color: #c58af9;
    }
    /* Dark mode hover - uses the dark mode variable */
    .dark-mode tbody tr:hover {
      background-color: var(--table-row-hover-bg);
    }

    /* --- UPDATED top-controls --- */
    .top-controls {
      display: flex;
      flex-direction: column;   /* Stack items vertically */
      align-items: flex-end;    /* Align items to the right */
      margin-bottom: 15px;
    }

    /* --- UPDATED #toggleBtn (Icon Button) --- */
     #toggleBtn {
        margin-bottom: 30px; /* Space below the button */
    }

     /* --- UPDATED #filterInput --- */
    #filterInput {
      width: 100%; /* Make input take full width */
      padding: 8px;
      margin: 0; /* Reset margin */
      box-sizing: border-box;
      border: 1px solid var(--input-border);
      border-radius: 4px;
      background-color: var(--input-bg);
      color: var(--text-color);
    }

    .button-container {
      margin-top: 10px;
      margin-bottom: 20px;
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
    }

    #noResultsMessage {
      text-align: center;
      margin-top: 30px;
      margin-bottom: 30px;
      color: var(--text-color);
      font-style: italic;
    }

    /* --- Icon Button Styles --- */
    .icon-button {
      padding: 8px; /* Adjust padding for icon */
      line-height: 0; /* Prevent extra space due to line height */
      width: 38px;  /* Slightly larger fixed width */
      height: 38px; /* Slightly larger fixed height */
      display: flex; /* Align icon center */
      align-items: center;
      justify-content: center;
      border-radius: 50%; /* Make it circular */
      /* No flex-shrink needed */
    }

     .icon-button:active {
        transform: scale(0.95); /* Override base button active scale if needed */
     }

    /* Styling for the icons within the button */
    .theme-icon {
      stroke: var(--button-text); /* Icon color inherits button text color */
      transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out; /* Smooth fade & slight rotate */
      position: absolute; /* Allow icons to overlap for transition */
    }

    /* --- Icon Visibility Control --- */
    /* Light Mode (Default): Show Sun, Hide Moon */
    #moon-icon {
       display: block; /* Keep in layout */
       opacity: 0;
       transform: rotate(-90deg) scale(0.5); /* Start rotated and small */
    }
    #sun-icon {
       display: block; /* Keep in layout */
       opacity: 1;
       transform: rotate(0deg) scale(1); /* Start normal */
    }
    /* Dark Mode: Hide Sun, Show Moon */
    .dark-mode #sun-icon {
       opacity: 0;
       transform: rotate(90deg) scale(0.5); /* Rotate out */
    }
    .dark-mode #moon-icon {
       opacity: 1;
       transform: rotate(0deg) scale(1); /* Rotate in */
    }
     /* Ensure icon color contrasts in dark mode */
     .dark-mode .icon-button .theme-icon {
       stroke: var(--button-text); /* Should already be white based on dark-mode vars */
     }
     /* --- End Icon Button Styles --- */

