/* Estilos padrões para até 480px */
@media (max-width: 480px) {
    .cabecalho {
        max-width: 480px;
        gap: 0.5rem;
    }

    .logo {
        width: 50px;
    }

    .titulo-cabecalho {
        font-size: 1.5rem;
        text-align: center;
    }

    .subtitulo-cabecalho {
        font-size: 0.9rem;
        text-align: center;
    }

    .toggle-switch {
        margin-top: 0.5rem;
        width: 50px;
        height: 25px;
    }

    .toggle-switch .slider {
        font-size: 20px;
        padding: 0 4px;
        border-radius: 10px;
        display: flex;
        align-items: center;
        position: relative;
        cursor: pointer;
        transition: background-color 0.4s;
    }

    .toggle-switch .slider::before {
        content: "";
        position: absolute;
        height: 36px;
        width: 36px;
        left: 2px;
        bottom: 2px;
        border-radius: 50%;
        transition: transform 0.4s ease;
    }

    .toggle-switch input {
        opacity: 0;
        width: 0;
        height: 0;
        position: absolute;
    }

    .toggle-switch input:checked + .slider::before {
        transform: translateX(10px);
    }

    .toggle-switch .slider i {
        font-size: 15px;
    }

    .toggle-switch .icone {
        opacity: 0;
        transition: opacity 0.3s ease;
        pointer-events: none;
    }

    .toggle-switch .icone.claro {
        opacity: 1;
    }

    .toggle-switch input:checked + .slider .icone.claro {
        opacity: 0;
    }

    .toggle-switch input:checked + .slider .icone.escuro {
        opacity: 1;
        color: var(--cor-primaria);
    }

    .form-filtros {
        flex-direction: column;
        gap: 1rem;
    }

    .form-filtros > div {
        flex: 1 1 100%;
        width: 100%;
    }

    .form-filtros button[type="submit"] {
        width: 100%;
        margin: 0;
    }

    .secao-lista-animes {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1rem;
    }

    footer.rodape {
        font-size: 0.8rem;
        padding: 0.8rem 1rem;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    header.cabecalho {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 1rem 2rem;
        gap: 15px;
    }

    .logo {
        width: 80px;
        margin-bottom: 0;
    }

    .titulo-cabecalho {
        font-size: 2rem;
        text-align: left;
        flex-grow: 1;
    }

    .subtitulo-cabecalho {
        font-size: 1rem;
        text-align: left;
        margin-left: 10px;
    }

    .toggle-switch {
        width: 200px;
        height: 30px;
        margin-top: 0;
        position: relative;
    }

    .toggle-switch .slider {
        font-size: 18px;
        padding: 0 8px;
        border-radius: 30px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
    }

    .toggle-switch .slider i {
        font-size: 22px;
        width: 22px;
        height: 22px;
        line-height: 22px;
    }

    .toggle-switch .slider::before {
        content: "";
        position: absolute;
        height: 26px;
        width: 26px;
        left: 2px;
        bottom: 2px;
        border-radius: 50%;
        transition: transform 0.4s ease;
        box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    }

    .toggle-switch input:checked + .slider::before {
        transform: translateX(30px);
    }

    .form-filtros {
        padding: 1.5rem 2rem;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1rem 2rem;
        align-items: center;
    }

    .grupos-filtros {
        width: 100%;
    }

    .secao-lista-animes {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
        padding: 1.5rem 2rem;
    }

    footer.rodape {
        font-size: 1rem;
        padding: 1rem 2rem;
    }
}

@media (min-width: 769px) and (max-width: 1023px) {
    header.cabecalho {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 2rem 4rem;
        gap: 25px;
    }

    .logo {
        width: 120px;
    }

    .titulo-cabecalho {
        font-size: 3rem;
        text-align: left;
        flex-grow: 1;
    }

    .subtitulo-cabecalho {
        font-size: 1.75rem;
        text-align: left;
        margin-left: 20px;
    }

    .toggle-switch {
        width: 100px;
        height: 40px;
        margin-top: 0;
        position: relative;
    }

    .toggle-switch .slider {
        font-size: 22px;
        padding: 0 12px;
        border-radius: 40px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
    }

    .toggle-switch .slider i {
        font-size: 26px;
        width: 26px;
        height: 26px;
        line-height: 26px;
    }

    .toggle-switch .slider::before {
        content: "";
        position: absolute;
        height: 36px;
        width: 36px;
        left: 2px;
        bottom: 2px;
        border-radius: 50%;
        transition: transform 0.4s ease;
        box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    }

    .toggle-switch input:checked + .slider::before {
        transform: translateX(36px);
    }

    .form-filtros {
        padding: 2rem 4rem;
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 2rem 3rem;
        align-items: center;
    }

    .grupos-filtros {
        width: 100%;
    }

    .secao-lista-animes {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 2.5rem;
        padding: 2rem 4rem;
    }

    footer.rodape {
        font-size: 1.2rem;
        padding: 1.5rem 4rem;
    }
}

@media (min-width: 1024px) and (max-width: 1366px) {
    header.cabecalho {
        padding: 1.5rem 3rem;
        gap: 20px;
    }

    .logo {
        width: 100px;
    }

    .titulo-cabecalho {
        font-size: 2.5rem;
    }

    .subtitulo-cabecalho {
        font-size: 1.25rem;
    }

    .toggle-switch {
        width: 70px;
        height: 36px;
        position: relative;
    }

    .toggle-switch .slider {
        font-size: 20px;
        padding: 0 10px;
        cursor: pointer;
    }

    .toggle-switch .slider i {
        font-size: 24px;
        width: 24px;
        height: 24px;
        line-height: 24px;
    }

    .toggle-switch .slider::before {
        content: "";
        position: absolute;
        height: 32px;
        width: 32px;
        left: 2px;
        bottom: 2px;
        border-radius: 50%;
        transition: transform 0.4s ease;
        box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    }

    .toggle-switch input:checked + .slider::before {
        transform: translateX(36px);
    }

    .form-filtros {
        padding: 2rem 3rem;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1.5rem;
    }

    .grupos-filtros {
        width: 100%;
    }

    .secao-lista-animes {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 2rem;
        padding: 2rem 3rem;
    }

    footer.rodape {
        font-size: 1.1rem;
        padding: 1rem 3rem;
    }
}